-
Notifications
You must be signed in to change notification settings - Fork 3
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
Fix missing "File:" prefix for uploads to Commons #63
Comments
Digging around a bit in the bot's contributions, it seems that it uploads the file twice, once with prefix and once without, e.g.
The order seems to vary:
|
Actually, that seems to be from two different runs. The one with the
"File:" prefix was uploaded July 2016, the other one just nowish.
…On Sat, Feb 18, 2017 at 4:41 PM Daniel Mietchen ***@***.***> wrote:
Digging around a bit, it seems that the bot uploads the file twice, with
prefix and without, e.g.
-
https://commons.wikimedia.org/wiki/File:A-Cost-Effectiveness-Tool-for-Informing-Policies-on-Zika-Virus-Control-pntd.0004743.g001.jpg
-
https://commons.wikimedia.org/wiki/A-Cost-Effectiveness-Tool-for-Informing-Policies-on-Zika-Virus-Control-pntd.0004743.g001.jpg
—
You are receiving this because you were assigned.
Reply to this email directly, view it on GitHub
<#63 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAKw7b-4yLYvMKP76ME3tvdpO24cvYukks5rd4-fgaJpZM4MFTa1>
.
|
That makes sense if one of the DOIs you ran today was a re-run of that July one. The point is that with "File:" is correct, without is not, and we should only upload the version with the prefix. |
I think I know what's going on now. Seems the mwclient API treats the page associated with an image file differently from pywikibot. Previously a page object needed to be created and associated with the file upload. I can move the metadata from there into the file upload itself and stop creating a separate page. |
Blocks #66. |
This causes the files to be treated as pages, which show up above the media files in
https://commons.wikimedia.org/wiki/Category:Uploaded_with_reCitation_Bot .
Like the probably related #62, this needs immediate fixing, since such uploads are not acceptable on Commons, which prevents further testing of the bot on Wikisource.
The text was updated successfully, but these errors were encountered: