Revision: 4996 Author: wikipedian Date: 2008-02-09 23:39:24 +0000 (Sat, 09 Feb 2008)
Log Message: ----------- added hack to get rid of all those lmo: interwiki links
Modified Paths: -------------- trunk/pywikipedia/interwiki.py
Modified: trunk/pywikipedia/interwiki.py =================================================================== --- trunk/pywikipedia/interwiki.py 2008-02-09 23:08:43 UTC (rev 4995) +++ trunk/pywikipedia/interwiki.py 2008-02-09 23:39:24 UTC (rev 4996) @@ -1076,8 +1076,16 @@ # Determine whether we need permission to submit ask = False if removing and removing != [page]: # Allow for special case of a self-pointing interwiki link - self.problem('Found incorrect link to %s in %s'% (",".join([x.site().lang for x in removing]), page.aslink(True)), createneed = False) - ask = True + ########## + # temporary hard-coded special case to get rid of thousands of broken links to the Lombard Wikipedia, + # where useless bot-created articles were mass-deleted. See for example: + # http://meta.wikimedia.org/wiki/Proposals_for_closing_projects/Closure_of_Lom... + if len(removing) == 1 and removing[0].site() == wikipedia.Site('lmo', 'wikipedia'): + wikipedia.output('Found bad link to %s. As many lmo pages were deleted, it is assumed that it can be safely removed.' % removing[0].aslink()) + else: + ########## + self.problem('Found incorrect link to %s in %s'% (",".join([x.site().lang for x in removing]), page.aslink(True)), createneed = False) + ask = True if globalvar.force: ask = False if globalvar.confirm: