On {T245209} I said that several py2 scripts I was maintaining were blocked from the same time, few days ago, and that they share the particularity of using the regularly updated version of the library on the tools. So I deduced, obviously too quickly, that pwb had voluntarily pushed a py3 patch only. @Dvorapa tells me that this is not the case, so I report the problem by creating this ticket.
First and last occurrence seen on my logs on February 13 2020 on py2 script using /shared/pywikibot/core/pwb.py (up-to-date to last master version). Not seen after switching to /data/project/pywikibot/public_html/core_python2/pwb.py (fixed python2 branch) the same day. Not part of bot code was edited to perform the switch successfully.
```
APIError: badinteger: Invalid value "3|0" for integer parameter "maxlag".
[help: See https://commons.wikimedia.org/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce> for notice of API deprecations and breaking changes.]
File "twitterwpfr.py", line 43, in run
self.imageDuJour()
File "twitterwpfr.py", line 75, in imageDuJour
assert pywikibot.FilePage(pywikibot.Site('commons', 'commons'), filename).exists()
File "pywikibot/page.py", line 815, in exists
return self.pageid > 0
File "pywikibot/page.py", line 292, in pageid
self.site.loadpageinfo(self)
File "pywikibot/site.py", line 2987, in loadpageinfo
self._update_page(page, query)
File "pywikibot/site.py", line 2967, in _update_page
for pageitem in query:
File "pywikibot/data/api.py", line 3001, in __iter__
for result in super(PropertyGenerator, self).__iter__():
File "pywikibot/data/api.py", line 2825, in __iter__
self.data = self.request.submit()
File "pywikibot/data/api.py", line 2094, in submit
raise APIError(**result['error'])
```
On another bot I maintain, using py2 and same pwb.py endpoint, with username that contains non ascii letters. 792 exceptions starting February 12 2020 07:01:50 CET. Logged version() output at this time was `[https] r-pywikibot-core.git (3dac747, g1, 2020/02/11, 17:23:13, ok)`.
```
OtherPageSaveError: Edit to page [[Wikipédia:Articles récents]] failed:
API write action attempted as IP u'Z\xe9roBot'
File "maj_articles_recents.py", line 556, in main
main_page.put(new_text, comment = comment)
File "pywikibot/tools/__init__.py", line 1790, in wrapper
return obj(*__args, **__kw)
File "pywikibot/tools/__init__.py", line 1790, in wrapper
return obj(*__args, **__kw)
File "pywikibot/page.py", line 1379, in put
**kwargs)
File "pywikibot/tools/__init__.py", line 1790, in wrapper
return obj(*__args, **__kw)
File "pywikibot/tools/__init__.py", line 1790, in wrapper
return obj(*__args, **__kw)
File "pywikibot/page.py", line 1301, in save
cc=apply_cosmetic_changes, quiet=quiet, **kwargs)
File "pywikibot/page.py", line 134, in wrapper
handle(func, self, *args, **kwargs)
File "pywikibot/page.py", line 126, in handle
raise pywikibot.OtherPageSaveError(self, err)
```
I don't know is these errors are excepted on the master branch.