Meno25 created this task.
Meno25 added projects: Pywikibot, Pywikibot-Scripts.
Restricted Application added subscribers: pywikibot-bugs-list, alaa, Aklapper.
TASK DESCRIPTION
**Command line:**
python pwb.py commonscat -site:wikiquote:ar -page:"الاستبداد"
**Output:**
Script terminated by exception:
ERROR: InvalidTitleError: 'Category:' has no title.
Traceback (most recent call last):
File "C:\Users\Mohammed\Downloads\core\pwb.py", line 365, in <module>
if not main():
File "C:\Users\Mohammed\Downloads\core\pwb.py", line 357, in main
run_python_file(filename,
File "C:\Users\Mohammed\Downloads\core\pwb.py", line 73, in
run_python_file
exec(compile(source, filename, 'exec', dont_inherit=True),
File ".\scripts\commonscat.py", line 552, in <module>
main()
File ".\scripts\commonscat.py", line 546, in main
bot.run()
File "C:\Users\Mohammed\Downloads\core\pywikibot\bot.py", line 1533, in
run
self.treat(page)
File "C:\Users\Mohammed\Downloads\core\pywikibot\bot.py", line 1814, in
treat
self.treat_page()
File ".\scripts\commonscat.py", line 318, in treat_page
commonscatLink = self.find_commons_category(page)
File ".\scripts\commonscat.py", line 412, in find_commons_category
return self.findCommonscatLink(page)
File ".\scripts\commonscat.py", line 385, in findCommonscatLink
checkedCommonscat = self.checkCommonscatLink(commonscatLink[1])
File ".\scripts\commonscat.py", line 454, in checkCommonscatLink
if not commonsPage.exists():
File "C:\Users\Mohammed\Downloads\core\pywikibot\page\__init__.py", line
710, in exists
return self.pageid > 0
File "C:\Users\Mohammed\Downloads\core\pywikibot\page\__init__.py", line
258, in pageid
self.site.loadpageinfo(self)
File "C:\Users\Mohammed\Downloads\core\pywikibot\page\__init__.py", line
195, in site
return self._link.site
File "C:\Users\Mohammed\Downloads\core\pywikibot\page\__init__.py", line
5382, in site
self.parse()
File "C:\Users\Mohammed\Downloads\core\pywikibot\page\__init__.py", line
5278, in parse
raise InvalidTitleError(
pywikibot.exceptions.InvalidTitleError: 'Category:' has no title.
CRITICAL: Exiting due to uncaught exception <class
'pywikibot.exceptions.InvalidTitleError'>
**Output of version.py:**
Pywikibot: [https] r-pywikibot-core (f60f6f3, g14825, 2021/05/12, 07:52:57,
master)
Release version: 6.2.0.dev0
requests version: 2.25.1
certificate test: ok
Python: 3.9.5 (tags/v3.9.5:0a7dcbd, May 3 2021, 17:27:52) [MSC v.1928 64
bit (AMD64)]
**Request:**
Please make the bot skip the page (and not crash) when encountering such
exceptions to save me the time to manually restart the bot every time it
crashes. Thank you.
TASK DETAIL
https://phabricator.wikimedia.org/T282693
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: Meno25
Cc: Aklapper, alaa, pywikibot-bugs-list, Meno25, Shalomori123, Jyoo1011,
JohnsonLee01, SHEKH, Dijkstra, Khutuck, Zkhalido, Viztor, Wenyi, Tbscho, MayS,
Mdupont, JJMC89, Dvorapa, Altostratus, Avicennasis, mys_721tx, jayvdb, Masti,
Alchimista
_______________________________________________
pywikibot-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]