Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[twitter] fix pattern for single tweet (#5371) #5372

Merged
merged 1 commit into from
Mar 26, 2024
Merged

Conversation

fireattack
Copy link
Contributor

@fireattack fireattack commented Mar 25, 2024

Fixes #5371.

@mikf
Copy link
Owner

mikf commented Mar 25, 2024

Thank you.

Could you update some of the test results to check for such URLs?

diff --git a/test/results/twitter.py b/test/results/twitter.py
index 2d43ebf8..715c1dae 100644
--- a/test/results/twitter.py
+++ b/test/results/twitter.py
@@ -316,7 +316,7 @@ __tests__ = (
 },
 
 {
-    "#url"     : "https://twitter.com/perrypumas/status/1065692031626829824",
+    "#url"     : "https://twitter.com/perrypumas/status/1065692031626829824?t=20",
     "#comment" : "video",
     "#category": ("", "twitter", "tweet"),
     "#class"   : twitter.TwitterTweetExtractor,
@@ -324,7 +324,7 @@ __tests__ = (
 },
 
 {
-    "#url"     : "https://twitter.com/playpokemon/status/1263832915173048321",
+    "#url"     : "https://twitter.com/playpokemon/status/1263832915173048321?",
     "#comment" : "content with emoji, newlines, hashtags (#338)",
     "#category": ("", "twitter", "tweet"),
     "#class"   : twitter.TwitterTweetExtractor,

@fireattack
Copy link
Contributor Author

fireattack commented Mar 25, 2024

Added some.

- Add optional slash
- Update tests to include some non-standard tweet URLs
@mikf mikf merged commit d1d017a into mikf:master Mar 26, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Twitter] gallery-dl fails to load URL if there's a '?' present
2 participants