-
-
Notifications
You must be signed in to change notification settings - Fork 402
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
wikipedia: support media fragments #2388
wikipedia: support media fragments #2388
Conversation
Both I and the reviewer missed a bug in #2383 that passed arguments to `str.join()` wrong. Switched to `str.format()` at another maintainer's suggestion. Co-authored-by: SnoopJ <snoopjedi@gmail.com>
927e951
to
08ccaa5
Compare
About handling File links directly: We probably don't want to open that can of worms this late in 8.0. But it can be a feature request for 8.1 if you see people post those. Maybe we should ask @xnaas if it's worthwhile, since SackBot gets a lot of traffic. The PR itself, though, |
bba75ea
to
d78961d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't gone hard enough at this to formally "Request changes", but I did have a couple comments.
༼ つ ◕_◕ ༽つ 8.0 Edit: Real answer: can save the "hardcore" stuff for when the plugin is extracted. :P |
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit, but you can squash that linter fixup anyway. 😉
Co-authored-by: dgw <dgw@technobabbl.es>
8b06bca
to
0728d35
Compare
Description
This PR adds support for Wikipedia links to media embedded in articles (i.e. fragments of the form
#/media/File:…
), which closes #2316Edit: While writing up the follow-up issue, I realized that
File:
is specific to English Wikipedia, so in 63187e9 the prefix check was relaxed to support other references to files on other language communities on Wikipedia. It seems to Just Work™ and the description retrieval is fairly cautious anyway.Note that this changeset does not emit an image description for links directly to a
File:…
article, but it's probably possible to rework it to do that too, if desiredChecklist
make qa
(runsmake quality
andmake test
)