Page MenuHomePhabricator

checkimages.py ignores -start parameter
Closed, DuplicatePublic

Description

Steps to reproduce:
Run
python pwb.py checkimages -limit:500 -commons -duplicatesreport -start:C or
python pwb.py checkimages -limit:500 -commons -duplicatesreport -start and in dialog where you should type name of page from which you should start type some letter

Expected behaviour
If I indicate to script should start from C it have to start from pages which starts with letter C

Actual behaviour
It starts from zero.

Output
Run of command

Zoran@Zoran-PC MINGW32 ~/Desktop/development/pywiki ((3381b74e...))
$ python pwb.py checkimages -limit:500 -commons -duplicatesreport -start
From which page do you want to start? C

Loading the allowed licenses...


You've set wrongly your settings, please take a look to the relative page. (run without them)
>> No additional settings found! <<
Checking if [[$RCO89PK.jpg]] is on commons...
Execution time: 12 seconds


Zoran@Zoran-PC MINGW32 ~/Desktop/development/pywiki ((3381b74e...))
$ python pwb.py checkimages -limit:500 -commons -duplicatesreport -start:C

Loading the allowed licenses...


You've set wrongly your settings, please take a look to the relative page. (run without them)
>> No additional settings found! <<
Checking if [[$RCO89PK.jpg]] is on commons...
Execution time: 5 seconds

Version

$ python pwb.py version
Pywikibot: [ssh] pywikibot-core (da9cc92, g10803, 2019/03/03, 12:38:58, ok)
Release version: 3.1.dev0
requests version: 2.21.0
  cacerts: C:\Users\Zoran\AppData\Local\Programs\Python\Python37-32\lib\site-packages\certifi\cacert.pem
    certificate test: ok
Python: 3.7.2 (tags/v3.7.2:9a3ffc0492, Dec 23 2018, 22:20:52) [MSC v.1916 32 bit (Intel)]
PYWIKIBOT_DIR: Not set
PYWIKIBOT_DIR_PWB:
PYWIKIBOT_NO_USER_CONFIG: Not set
Config base dir: C:\Users\Zoran\Desktop\development\pywiki
Usernames for family "wikipedia":
        sr: ZoranBot (no sysop configured)
Usernames for family "wiktionary":
        sr: Zoranzoki21 (also sysop)

Event Timeline

Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. · View Herald TranscriptMar 3 2019, 3:50 PM
Zoranzoki21 updated the task description. (Show Details)Mar 3 2019, 3:56 PM
Zoranzoki21 updated the task description. (Show Details)Mar 3 2019, 3:59 PM
Dvorapa added a subscriber: Dvorapa.EditedMar 3 2019, 4:46 PM

Well, it starts from C, but in main namespace (Gallery namespace, ns:0), where no images are found. In order to start from C, you need to use -start:File:C. But yes, the docs (pwb.py checkimages -help ) should be more clear about this and perhaps it would be good to make File:prefix automatically assumed. BTW also -start:C -ns:6 does not work as expected, which is more serious issue than the first one.

Well, it starts from C, but in main namespace (Gallery namespace, ns:0), where no images are found. In order to start from C, you need to use -start:File:C. But yes, the docs (pwb.py checkimages -help ) should be more clear about this and perhaps it would be good to make File:prefix automatically assumed. BTW also -start:C -ns:6 does not work as expected, which is more serious issue than the first one.

Oh, I forgot to try with File.. I will close this as invalid, because script works as expected and I will make patch.