Revision: 5641 Author: filnik Date: 2008-06-26 21:11:12 +0000 (Thu, 26 Jun 2008)
Log Message: ----------- Fixing regex to detect the log
Modified Paths: -------------- trunk/pywikipedia/checkimages.py
Modified: trunk/pywikipedia/checkimages.py =================================================================== --- trunk/pywikipedia/checkimages.py 2008-06-26 19:39:48 UTC (rev 5640) +++ trunk/pywikipedia/checkimages.py 2008-06-26 21:11:12 UTC (rev 5641) @@ -702,7 +702,7 @@ self.image = image wikipedia.output(u'Checking if %s is on commons...' % self.image) commons_site = wikipedia.getSite('commons', 'commons') - regexOnCommons = r"\n*[[:Image:%s]] is also on '''Commons''': [[commons:Image:%s]]$" % (self.image, self.image) + regexOnCommons = r"\n*[[:Image:%s]] is also on '''Commons''': [[commons:Image:.*?]]$" % self.image imagePage = wikipedia.ImagePage(self.site, 'Image:%s' % self.image) hash_found = imagePage.getHash() commons_image_with_this_hash = commons_site.getImagesFromAnHash(hash_found)
pywikipedia-l@lists.wikimedia.org