https://bugzilla.wikimedia.org/show_bug.cgi?id=69133
Bug ID: 69133
Summary: unusedfiles raises NoPage for redirect to deleted file
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: major
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
The first item on [[Special:UnusedFiles]] is currently
[[File:Song_of_the_Thin_Man_(videocassette_cover_art).jpg]], which is deleted,
however it has an incoming redirect which might be why it is still in
unusedfiles, or perhaps a caching issue.
This causes unusedfiles to raise an exception, and there is no way to bypass it
as the script only uses special:unusedfiles as a generator.
$ python pwb.py scripts/unusedfiles.py
Retrieving 50 pages from wikipedia:en.
WARNING: Http response status 404
>> File:Song of the Thin Man (videocassette cover
art).jpg <<<
Traceback (most recent call last):
File "pwb.py", line 166, in <module>
run_python_file(fn, argv, argvu)
File "pwb.py", line 67, in run_python_file
exec(compile(source, filename, "exec"), main_mod.__dict__)
File "scripts/unusedfiles.py", line 117, in <module>
main()
File "scripts/unusedfiles.py", line 108, in main
appendtext(image, u"\n\n" + template_image, always)
File "scripts/unusedfiles.py", line 58, in appendtext
raise pywikibot.NoPage(u"Page '%s' does not exist" % page.title())
pywikibot.exceptions.NoPage: Page Page 'File:Song of the Thin Man
(videocassette cover art).jpg' does not exist doesn't exist.
<class 'pywikibot.exceptions.NoPage'>
--
You are receiving this mail because:
You are the assignee for the bug.