yarl / pattypan

Upload files to Wikimedia Commons. The Spreadsheet Way.
https://commons.wikimedia.org/wiki/Commons:Pattypan
MIT License
56 stars 37 forks source link

21.10-experimental2 stops at radom images #145

Closed Aktron closed 2 years ago

Aktron commented 2 years ago

The great news is that 21.10-experimental2 works and uploads images to Commons!

The bad news is that the uploading process tends to be interrupted at random when uploading some images. As far as I tried (I uploaded cca 300 images with 21.10-experimental2) I can see no pattern in which images are stopping the upload. It seems to be a bit more likely if the filename includes "01" string. But some others tend to stop the uploading process too. Thats the only similiarity I found.

The whole thing just stops, there is no error message or anything similar :-/

This error did not occur prior to Oct 1 and the change of Mediawiki or upgrade of Pattypan.

pattypan 2021-10-13 20_17_24.xls This is an example spreadhseet I used. The uploading process stops at file on line 23 for no apparent reason :-(

Aktron commented 2 years ago

Turns out the blocking element is somewhere in the filename string. If the files are renamed both in the folder and in the "A" column of the spreadsheet then everything works fine. So we have a workaround, although an uneasy one.

Abbe98 commented 2 years ago

@Aktron thank you for the report! Indeed this should not have been the previous behavior, an error should have been raised but the upload should have continued. Do you have the Pattypan log at hand?

Aktron commented 2 years ago

Unfortunately not :-( I have completed the uploading session already. So far it seems that for 600 files it makes about 11 those who trigger this bug. I have checked the text output from console and so far I haven't found anything suspicious :-( Otherwise I'd paste it here. Just one question: Is the "log" this thing or can I find it somewhere else?

Abbe98 commented 2 years ago

Pattypan writes its log to a file accessible from Pattypan's start page, it should, however, be the same as the console output.

Aktron commented 2 years ago

I see. It crashes when I try to download it, then again I upload with pattypan a lot ;-) I will copy the output from terminal once I'll be uploading new files.

Aktron commented 2 years ago

Supplemental: It seems this bug does not appear anymore. At least it did not during the last two uploads. I will be cautious and in case I'll find something like this in the future I'll report it here.

TheKnightWho commented 2 years ago

I don't seem to be able to manage any uploads unfortunately. Not sure if it's to do with my filename schema that the bug is hitting all of them, or whether it's just a general bug.

Abbe98 commented 2 years ago

@TheKnightWho, do you have a log or filename examples to share?

albertoleoncio commented 2 years ago

@TheKnightWho, do you have a log or filename examples to share?

Sure! I have the same problem when I upload. The error appears to be completely random, and I only notice that it has crashed when the network activity indicator stops blinking. When I restart pattypan to try the upload again, the error persists. It only works when I change some character in the filename and in the excel table (changing a space for an underline is enough).

alberto@alberto-VirtualBox:~$ java --module-path "/usr/share/openjfx/lib/" --add-modules javafx.web -jar pattypan-2.jar
nov 05, 2021 11:15:47 AM pattypan.Main main
INFORMAÇÕES: Wiki set as: commons.wikimedia.org
Protocol set as: https://
Script path set as: /w
nov 05, 2021 11:15:47 AM pattypan.Main main
INFORMAÇÕES: Operating System: Linux
Pattypan Version: 21.10
nov 05, 2021 11:16:38 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=login
nov 05, 2021 11:16:40 AM Wiki login
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=login
nov 05, 2021 11:16:42 AM Wiki getUserInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&usprop=editcount%7Cgroups%7Crights%7Cemailable%7Cblockinfo%7Cgender%7Cregistration&maxlag=5&format=xml&action=query&list=users
nov 05, 2021 11:16:42 AM Wiki getSiteInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&siprop=namespaces%7Cnamespacealiases%7Cgeneral%7Cextensions&maxlag=5&meta=siteinfo&format=xml&action=query
nov 05, 2021 11:16:43 AM Wiki getSiteInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved site info for commons.wikimedia.org
nov 05, 2021 11:16:43 AM Wiki getUsers
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved user info for 1 users.
nov 05, 2021 11:16:43 AM Wiki login
INFORMAÇÕES: [commons.wikimedia.org] Successfully logged in as ALeoncio (WMB), highLimit = false
nov 05, 2021 11:16:46 AM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 11:16:46 AM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 11:16:46 AM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 11:16:46 AM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 11:16:46 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:16:48 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:17:06 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:17:07 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:17:34 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:17:36 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:18:03 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:18:04 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:18:19 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:18:20 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:18:48 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:18:49 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:19:16 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:19:18 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:19:32 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:19:34 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:20:04 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:20:05 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:20:33 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:20:34 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:21:03 AM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 11:21:04 AM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 11:21:10 AM Wiki upload
INFORMAÇÕES: [commons.wikimedia.org] Successfully uploaded to File:BR RJANRIO BI - D16 165.pdf.

[...]

nov 05, 2021 12:06:45 PM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 12:06:45 PM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 12:06:45 PM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 12:06:46 PM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 12:06:46 PM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 12:06:47 PM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 12:07:04 PM Wiki upload
INFORMAÇÕES: [commons.wikimedia.org] Successfully uploaded to File:BR RJANRIO BI - D16 188.pdf.
nov 05, 2021 12:07:04 PM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 12:07:05 PM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 12:07:05 PM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 12:07:05 PM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 12:07:05 PM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 12:07:06 PM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
nov 05, 2021 12:07:27 PM Wiki upload
INFORMAÇÕES: [commons.wikimedia.org] Successfully uploaded to File:BR RJANRIO BI - D16 189.pdf.
nov 05, 2021 12:07:27 PM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 12:07:27 PM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 12:07:27 PM Wiki getPageInfo
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query
nov 05, 2021 12:07:28 PM Wiki getPageInfo
INFORMAÇÕES: [commons.wikimedia.org] Successfully retrieved page info for 1 pages.
nov 05, 2021 12:07:28 PM Wiki getToken
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=csrf
nov 05, 2021 12:07:28 PM Wiki upload
INFORMAÇÕES: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=upload
TheKnightWho commented 2 years ago

Here's the xls file I've been using to upload. They're SVGs of Korean Hangul, FYI. None of them seem to be uploading. pattypan 2021-10-30 23_18_08.xls .

geagea1 commented 2 years ago

I have the same issue see https://commons.wikimedia.org/wiki/Commons_talk:Pattypan#pattypan_21.10_upload_stucks

Aktron commented 2 years ago

Hi. I have to say, as of recently my wife has experienced this problem as well when uploading cca 600 images. The spreadsheet file is here: pattypan 2021-12-01 11_50_25.xls

MER-C commented 2 years ago

I have fixed the underlying problem. See wiki-java d270616.

Abbe98 commented 2 years ago

I have published a new release with the upstream changes to resolve this:

https://github.com/Kartkod/pattypan/releases/tag/pattypan-21-10-experimental-4

annalauraw commented 2 years ago

I also encountered the issue - my test load with two images got stuck at the first image with 21.10-experimental-2 and 21.10-experimental-3. Is there a chance to get the .jar file for 21.10-experimental-4 as with the previous releases, or do I have to compile them with ant?

Abbe98 commented 2 years ago

@annalauraw I have added the JAR to the release(I had missed it).

annalauraw commented 2 years ago

I still have the same issue with 21.10-experimental-4: my test load gets stuck at the first image (tested on Windows 10 with two different .xls files, two images each). Here's an example: pattypan_test_2021-12-20_teil_1.xls

And here's the Pattypan output: C:\Users\wieg>java --module-path %PATH_TO_FX% --add-modules javafx.web -jar C:\Users\wieg\Downloads\pattypan-21-10-experimental-4.jar Jan. 31, 2022 2:34:34 NACHM. pattypan.Main main INFO: Wiki set as: commons.wikimedia.org Protocol set as: https:// Script path set as: /w Jan. 31, 2022 2:34:35 NACHM. pattypan.Main main INFO: Operating System: Windows 10 Pattypan Version: 21.10 Jan. 31, 2022 2:39:34 NACHM. Wiki getToken INFO: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&meta=tokens&format=xml&action=query&type=login Jan. 31, 2022 2:39:35 NACHM. Wiki login INFO: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&format=xml&action=login Jan. 31, 2022 2:39:36 NACHM. Wiki getUserInfo INFO: Fetching URL https://commons.wikimedia.org/w/api.php?&usprop=editcount%7Cgroups%7Crights%7Cemailable%7Cblockinfo%7Cgender%7Cregistration&maxlag=5&format=xml&action=query&list=users Jan. 31, 2022 2:39:36 NACHM. Wiki getSiteInfo INFO: Fetching URL https://commons.wikimedia.org/w/api.php?&siprop=namespaces%7Cnamespacealiases%7Cgeneral%7Cextensions&maxlag=5&meta=siteinfo&format=xml&action=query Jan. 31, 2022 2:39:36 NACHM. Wiki getSiteInfo INFO: [commons.wikimedia.org] Successfully retrieved site info for commons.wikimedia.org Jan. 31, 2022 2:39:36 NACHM. Wiki getUsers INFO: [commons.wikimedia.org] Successfully retrieved user info for 1 users. Jan. 31, 2022 2:39:36 NACHM. Wiki login INFO: [commons.wikimedia.org] Successfully logged in as Zentralbibliothek Z³rich, highLimit = false Jan. 31, 2022 2:39:39 NACHM. Wiki getPageInfo INFO: Fetching URL https://commons.wikimedia.org/w/api.php?&maxlag=5&prop=info&inprop=protection%7Cdisplaytitle%7Cwatchers&format=xml&action=query

Java version: java 11.0.10 2021-01-19 LTS Java(TM) SE Runtime Environment 18.9 (build 11.0.10+8-LTS-162) Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11.0.10+8-LTS-162, mixed mode)

OpenJFX version: javafx-sdk-17.0.1

Abbe98 commented 2 years ago

@annalauraw thank you for letting us know!

MER-C commented 2 years ago

@annalauraw Please provide a download link to the images.

annalauraw commented 2 years ago

@MER-C please find my two test load images here: https://drive.switch.ch/index.php/s/nXiYUN34qGfhQsZ.

MER-C commented 2 years ago

The latest Wiki.java is able to upload these images without problems.

https://test.wikipedia.org/wiki/File:Test1236.jpg https://test.wikipedia.org/wiki/File:Test1237.jpg

Abbe98 commented 2 years ago

I have been unable to reproduce this too.