http://www.mediawiki.org/wiki/Special:Code/pywikipedia/10746
Revision: 10746 Author: amir Date: 2012-11-22 12:00:12 +0000 (Thu, 22 Nov 2012) Log Message: ----------- speedy fix for bug #3587728
Modified Paths: -------------- trunk/pywikipedia/wikipedia.py
Modified: trunk/pywikipedia/wikipedia.py =================================================================== --- trunk/pywikipedia/wikipedia.py 2012-11-20 13:03:05 UTC (rev 10745) +++ trunk/pywikipedia/wikipedia.py 2012-11-22 12:00:12 UTC (rev 10746) @@ -757,7 +757,7 @@ #'intoken': 'edit', } params1=params.copy() - if self.site().lang==u"wikidata": + if self.site().lang==u"wikidata" and self.namespace()==0: params['action']='wbgetentities' params['sites']='enwiki' del params['prop'] @@ -774,7 +774,7 @@ textareaFound = False # retrying loop is done by query.GetData data = query.GetData(params, self.site(), sysop=sysop) - if self.site().lang==u"wikidata": + if self.site().lang==u"wikidata" and self.namespace()==0: data['query']={'pages':data['entities']} for pageid in data['entities'].keys(): if pageid=="-1":