Dalba has uploaded a new change for review. https://gerrit.wikimedia.org/r/322232
Change subject: APIGenerator.set_maximum_items: Don't compare int with None ...................................................................... APIGenerator.set_maximum_items: Don't compare int with None `query_increment` can be None. In Python 2 None is less than any number but Python 3 raises "TypeError: unorderable types: int() < NoneType()". test_continue (tests.site_tests.TestDataSiteSearchEntities) was failing on because of this issue. Change-Id: I73e711014303a397a1009c76798d2cfefabc608b --- M pywikibot/data/api.py 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core refs/changes/32/322232/1 diff --git a/pywikibot/data/api.py b/pywikibot/data/api.py index c087bb5..3b2ae9d 100644 --- a/pywikibot/data/api.py +++ b/pywikibot/data/api.py @@ -2435,7 +2435,7 @@ @type value: int """ self.limit = int(value) - if self.limit < self.query_increment: + if self.query_increment and self.limit < self.query_increment: self.request[self.limit_name] = self.limit pywikibot.debug(u"%s: Set request item limit to %i" % (self.__class__.__name__, self.limit), _logger) -- To view, visit https://gerrit.wikimedia.org/r/322232 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I73e711014303a397a1009c76798d2cfefabc608b Gerrit-PatchSet: 1 Gerrit-Project: pywikibot/core Gerrit-Branch: master Gerrit-Owner: Dalba <dalba.w...@gmail.com> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits