Revision: 5591 Author: a_engels Date: 2008-06-17 21:51:38 +0000 (Tue, 17 Jun 2008)
Log Message: ----------- avoid an error message
Modified Paths: -------------- trunk/pywikipedia/solve_disambiguation.py
Modified: trunk/pywikipedia/solve_disambiguation.py =================================================================== --- trunk/pywikipedia/solve_disambiguation.py 2008-06-17 21:51:18 UTC (rev 5590) +++ trunk/pywikipedia/solve_disambiguation.py 2008-06-17 21:51:38 UTC (rev 5591) @@ -622,8 +622,11 @@ if m.group('title') == '' or self.mysite.isInterwikiLink(m.group('title')): continue else: - linkPage = wikipedia.Page(disambPage.site(), m.group('title')) - # Check whether the link found is to disambPage. + try: + linkPage = wikipedia.Page(disambPage.site(), m.group('title')) + # Check whether the link found is to disambPage. + except wikipedia.InvalidTitle: + continue if linkPage != disambPage: continue