Bugs item #3147994, was opened at 2010-12-30 07:46 Message generated for change (Comment added) made by xqt You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=603138&aid=3147994...
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: interwiki Group: None
Status: Closed Resolution: Fixed
Priority: 5 Private: No Submitted By: Mikko Silvonen (silvonen)
Assigned to: xqt (xqt)
Summary: interwiki.py crashes on redirected section link
Initial Comment: interwiki.py crashes on the link [[sv:Lista över kortspel#P]], which is a redirect to [[sv:Kategori:Kortspel]].
interwiki.py -lang:fi Paskahousu
Getting 1 pages from wikipedia:fi... [[Paskahousu]]: [[fi:Paskahousu]] gives new interwiki [[en:Paskahousu]] [[Paskahousu]]: [[fi:Paskahousu]] gives new interwiki [[sv:Lista över kortspel#P]] Getting 1 pages from wikipedia:en... Getting 1 pages from wikipedia:sv... WARNING: Section not found: [[sv:Lista över kortspel#P]] Kategori:Kortspel#P 17 None Dump fi (wikipedia) appended. Traceback (most recent call last): File "C:\svn\pywikipedia\interwiki.py", line 2673, in <module> main() File "C:\svn\pywikipedia\interwiki.py", line 2647, in main bot.run() File "C:\svn\pywikipedia\interwiki.py", line 2390, in run self.queryStep() File "C:\svn\pywikipedia\interwiki.py", line 2363, in queryStep self.oneQuery() File "C:\svn\pywikipedia\interwiki.py", line 2359, in oneQuery subject.batchLoaded(self) File "C:\svn\pywikipedia\interwiki.py", line 1399, in batchLoaded % (page.aslink(True), redir, redirectTargetPage.aslink(True))) File "c:\svn\pywikipedia\wikipedia.py", line 571, in aslink allowInterwiki=not noInterwiki, textlink=textlink) File "c:\svn\pywikipedia\wikipedia.py", line 465, in title title = title[:begin + 1] + anchor TypeError: coercing to Unicode: need string or buffer, NoneType found
python version.py
Pywikipedia [http] trunk/pywikipedia (r8813, 2010/12/29, 22:27:03) Python 2.5.4 (r254:67916, Jan 29 2009, 12:02:11) [MSC v.1310 32 bit (Intel)] config-settings: use_api = True use_api_login = True unicode test: ok
----------------------------------------------------------------------
Comment By: xqt (xqt)
Date: 2010-12-31 11:42
Message: categories does not have sections. Invalid section error introduced in r8815.
----------------------------------------------------------------------
You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=603138&aid=3147994...
pywikipedia-bugs@lists.wikimedia.org