http://www.mediawiki.org/wiki/Special:Code/pywikipedia/10289
Revision: 10289 Author: xqt Date: 2012-06-03 21:32:04 +0000 (Sun, 03 Jun 2012) Log Message: ----------- comment out debugging stuff, test whether QueryGenerator hasattr(self, "data") (fix for r10285)
Modified Paths: -------------- branches/rewrite/pywikibot/data/api.py
Modified: branches/rewrite/pywikibot/data/api.py =================================================================== --- branches/rewrite/pywikibot/data/api.py 2012-06-03 14:35:52 UTC (rev 10288) +++ branches/rewrite/pywikibot/data/api.py 2012-06-03 21:32:04 UTC (rev 10289) @@ -266,9 +266,9 @@ headers={'Content-Type': 'application/x-www-form-urlencoded'}, body=paramstring) - import traceback - traceback.print_stack() - print rawdata +## import traceback +## traceback.print_stack() +## print rawdata except Server504Error: pywikibot.log(u"Caught HTTP 504 error; retrying") self.wait() @@ -605,7 +605,7 @@ new_limit = min(new_limit, self.api_limit // 10, 250) if new_limit is not None: self.request[self.prefix+"limit"] = str(new_limit) - if not self.data: + if not hasattr(self, "data"): try: self.data = self.request.submit() except Server504Error: