Page MenuHomePhabricator

Pywikibot confuses simplewiki with wikidata
Open, Needs TriagePublic

Description

2025-11-02T20:23:29Z [archivebot-run-wsczw] [job] pywikibot.exceptions.NoUsernameError: Failed OAuth authentication for wikidata:wikidata: The authorization headers in your request are for a user that does not exist here ***
---
- command: pwb -family:wikipedia -lang:simple archivebot User:MiszaBot/config -page:Main_Page -namespace:1
  image: tool-pywikibot/pywikibot-scripts-stable:latest
  name: bot873-archive-main-page-talk
  schedule: "@daily"

Beginning approximately mid-October, Bot873, running on pywikibot archivebot on simplewiki, began failing to archive namespace:1, 5, and 6 reliably. While investigating, I uncovered errors related to failure to pass OAUTH on wikidata. The family is set in command to wikipedia and the language to simple. I've reviewed the code in the repos, but unable to find something that might have changed that caused this issue.

I've verified envvars on toolforge are set correctly. I noted some version increments around this time and wanted to request assistance investigating the issue further.

Event Timeline

It's also relevant to add that the bot works as expected when archiving user talk pages.

Wasn't able to reproduce it:

C:\pwb\GIT\core>py -3.13 -m pwb -site:wikipedia:simple -user:<redacted> -simulate archivebot User:MiszaBot/config -page:Talk:Main_Page

>>> [[simple:Talk:Main Page]] <<<
11 thread(s) found on [[simple:Talk:Main Page]]
69 thread(s) found on [[simple:Talk:Main Page/Archive5]]
Archiving 2 thread(s).
Logging in to wikipedia:simple as <redacted>
SIMULATION: edit action blocked.
Page [[Talk:Main Page/Archive5]] saved
SIMULATION: edit action blocked.
Page [[Talk:Main Page]] saved

Execution time: 6 seconds

What is the current Pywikibot release you are using (pwb version)?

I found some problems with logging in on beta cluster (T408721) recently; maybe it is an upstream issue.

It is also strange that wikidata is used becaus this is (should be) only the case for new archive pages when an archive header is missing in the archiving template and a default template is added but the archiveheader is given with the config template.

Please also check the command line because -page:Main_Page means User:Main_Page

-page:Main_Page -namespace:1 should translate to Talk:Main_Page and has worked previously. I'll get the current version information when next I have a moment to log in.

version information resulting from toolforge jobs run bot873-version --image tool-pywikibot/pywikibot-scripts-stable:latest --command 'pwb version' follow:

2025-11-03T14:33:05Z [bot873-version-z9gvv] [job] Release version: 10.5.0
2025-11-03T14:33:05Z [bot873-version-z9gvv] [job] packaging version: 25.0
2025-11-03T14:33:05Z [bot873-version-z9gvv] [job] mwparserfromhell version: 0.7.2
2025-11-03T14:33:05Z [bot873-version-z9gvv] [job] wikitextparser version: 0.56.4
2025-11-03T14:33:05Z [bot873-version-z9gvv] [job] requests version: 2.32.5

I'm using the pywikibot toolforge image which is (obviously) remotely maintained. I flushed the jobs from toolforge and rebuilt them. Waiting to see if the IT fairies work in the 'turn it off and back on again' magic.

-page:Main_Page -namespace:1 should translate to Talk:Main_Page and has worked previously. I'll get the current version information when next I have a moment to log in.

If the toolforge repository is unchanged for the FilePage ns parameter from the original Pywikibot repo, it cannot work with -namespace option:

elif pagename:
    gen = [pywikibot.Page(site, pagename, ns=3)]

but throws an message [[simple:User talk:Main Page]] does not exist, skipping...

Anyway it would be a good idea to have it working.

Change #1201088 had a related patch set uploaded (by Xqt; author: Xqt):

[pywikibot/core@master] [IMPR] respect the ``-namespace`` option with ``-page`` option

https://gerrit.wikimedia.org/r/1201088

tools.bot873@tools-bastion-15:~/pywikibot$ toolforge jobs run bot873-talk-main-page-test --image tool-pywikibot/pywikibot-scripts-stable:latest --command "pwb -family:wikipedia -lang:simple archivebot User:MiszaBot/config -page:Main_Page -namespace:1"
tools.bot873@tools-bastion-15:~/pywikibot$ toolforge jobs logs bot873-talk-main-page-test
2025-11-03T17:21:22Z [bot873-talk-main-page-test-wskdj] [job] family and mylang are not set.
2025-11-03T17:21:22Z [bot873-talk-main-page-test-wskdj] [job] Defaulting to family='wikipedia' and mylang='test'.
2025-11-03T17:21:23Z [bot873-talk-main-page-test-wskdj] [job] [[simple:User talk:Main Page]] does not exist, skipping...
2025-11-03T17:21:23Z [bot873-talk-main-page-test-wskdj] [job]
2025-11-03T17:21:23Z [bot873-talk-main-page-test-wskdj] [job] Execution time: 0 seconds

Did another test run just now, curious the first line of log... "family and mylang are not set" yet clearly set with -family:wikipedia -lang:simple. Interesting, indeed. As far as I'm aware, this is still version 10.6.0 and I saw your change on gerrit.

Solution is the drop the -namespace switch for now and specify page:Talk:Main_Page which gets the job done.

Actually.... confused again. Seems like it's correctly selecting the family/language but panics when the new archive page doesn't exist ahead of archiving? I'll check/update the OAuth info and try again since I don't think fetching page content is privileged via API but creating/editing/etc would be. Perhaps creds expired?

Result of tools.bot873@tools-bastion-15:~$ toolforge jobs run bot873-wp-archive-test --image tool-pywikibot/pywikibot-scripts-stable:latest --command "pwb -family:wikipedia -lang:simple archivebot User:MiszaBot/config -namespace:4" follows:

2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] WARNING: API error mwoauth-invalid-authorization-invalid-user: The authorization headers in your request are for a user that does not exist here
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] ERROR: Error occurred while processing page [[simple:Wikipedia:Simple talk]]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] WARNING: API error mwoauth-invalid-authorization-invalid-user: The authorization headers in your request are for a user that does not exist here
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] ERROR: Error occurred while processing page [[simple:Wikipedia:Administrators' noticeboard]]
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     if self.userinfo['name'] == self.user():
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 672, in userinfo
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     if self.userinfo['name'] == self.user():
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 672, in userinfo
2025-11-03T17:38:49Z [bot873-wp-archive-test-b7n9h] [job] family and mylang are not set.
2025-11-03T17:38:49Z [bot873-wp-archive-test-b7n9h] [job] Defaulting to family='wikipedia' and mylang='test'.
2025-11-03T17:38:50Z [bot873-wp-archive-test-b7n9h] [job] Fetching User:MiszaBot/config template transclusions...
2025-11-03T17:38:51Z [bot873-wp-archive-test-b7n9h] [job]  ***
2025-11-03T17:38:51Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:38:51Z [bot873-wp-archive-test-b7n9h] [job] >>> [[simple:Wikipedia:Simple talk]] <<< ***
2025-11-03T17:38:52Z [bot873-wp-archive-test-b7n9h] [job] 59 thread(s) found on [[simple:Wikipedia:Simple talk]]
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] 59 thread(s) found on [[simple:Wikipedia:Simple talk/Archive 170]]
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] Traceback (most recent call last):
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 475, in load_page
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     text = self.get()
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/page/_basepage.py", line 383, in get
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     self._getInternals()
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/page/_basepage.py", line 430, in _getInternals
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     self.site.loadrevisions(self, content=True)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_generators.py", line 863, in loadrevisions
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     raise NoPageError(page)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] pywikibot.exceptions.NoPageError: Page [[simple:Wikipedia:Simple talk/Archive 171]] doesn't exist.
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] During handling of the above exception, another exception occurred:
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] Traceback (most recent call last):
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 983, in process_page
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     archiver.run()
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 900, in run
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     whys = self.analyze_page()
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 871, in analyze_page
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     while archive.is_full(max_arch_size):
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 527, in is_full
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     self_size = self.size()
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 552, in size
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     if not (self.exists() or self.threads):
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 414, in __getattr__
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     self.load_page()
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 478, in load_page
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     self.get_header_template())
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 456, in get_header_template
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     tpl = self.site.page_from_repository(item)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 1381, in page_from_repository
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     if not self.has_data_repository:
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 1283, in has_data_repository
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     return self.data_repository() is not None
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 1315, in data_repository
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     return pywikibot.Site(url=url, user=self.username(),
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/__init__.py", line 205, in Site
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     code, fam = _code_fam_from_url(url, fam)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/__init__.py", line 108, in _code_fam_from_url
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     code = family.from_url(url)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/family.py", line 633, in from_url
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     site = pywikibot.Site(code, self.name)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/__init__.py", line 254, in Site
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     _sites[key] = interface(code=code, fam=fam, user=user)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_datasite.py", line 40, in __init__
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     super().__init__(*args, **kwargs)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 138, in __init__
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     self.login(cookie_only=True)
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 394, in login
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     uidata = uirequest.submit()
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/data/api/_requests.py", line 1148, in submit
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]     raise NoUsernameError(f'Failed {msg}')
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] pywikibot.exceptions.NoUsernameError: Failed OAuth authentication for wikidata:wikidata: The authorization headers in your request are for a user that does not exist here ***
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:38:56Z [bot873-wp-archive-test-b7n9h] [job] >>> [[simple:Wikipedia:Administrators' noticeboard]] <<< ***
2025-11-03T17:38:57Z [bot873-wp-archive-test-b7n9h] [job] 39 thread(s) found on [[simple:Wikipedia:Administrators' noticeboard]]
2025-11-03T17:38:59Z [bot873-wp-archive-test-b7n9h] [job] 48 thread(s) found on [[simple:Wikipedia:Administrators' noticeboard/Current issues and requests archive 87]]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] Traceback (most recent call last):
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 475, in load_page
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     text = self.get()
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/page/_basepage.py", line 383, in get
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     self._getInternals()
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/page/_basepage.py", line 430, in _getInternals
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     self.site.loadrevisions(self, content=True)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_generators.py", line 863, in loadrevisions
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     raise NoPageError(page)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] pywikibot.exceptions.NoPageError: Page [[simple:Wikipedia:Administrators' noticeboard/Current issues and requests archive 88]] doesn't exist.
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] During handling of the above exception, another exception occurred:
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] Traceback (most recent call last):
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 983, in process_page
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     archiver.run()
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 900, in run
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     whys = self.analyze_page()
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 871, in analyze_page
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     while archive.is_full(max_arch_size):
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 527, in is_full
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     self_size = self.size()
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 552, in size
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     if not (self.exists() or self.threads):
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 414, in __getattr__
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     self.load_page()
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 478, in load_page
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     self.get_header_template())
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/scripts/archivebot.py", line 456, in get_header_template
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     tpl = self.site.page_from_repository(item)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 1381, in page_from_repository
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     if not self.has_data_repository:
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 1283, in has_data_repository
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     return self.data_repository() is not None
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 1315, in data_repository
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     return pywikibot.Site(url=url, user=self.username(),
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/__init__.py", line 205, in Site
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     code, fam = _code_fam_from_url(url, fam)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/__init__.py", line 108, in _code_fam_from_url
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     code = family.from_url(url)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/family.py", line 633, in from_url
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     site = pywikibot.Site(code, self.name)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/__init__.py", line 254, in Site
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     _sites[key] = interface(code=code, fam=fam, user=user)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_datasite.py", line 40, in __init__
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     super().__init__(*args, **kwargs)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 138, in __init__
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     self.login(cookie_only=True)
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/site/_apisite.py", line 394, in login
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     uidata = uirequest.submit()
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]   File "/workspace/pywikibot/data/api/_requests.py", line 1148, in submit
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]     raise NoUsernameError(f'Failed {msg}')
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] pywikibot.exceptions.NoUsernameError: Failed OAuth authentication for wikidata:wikidata: The authorization headers in your request are for a user that does not exist here ***
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] >>> [[simple:Wikipedia:Change filter/Mistakes]] <<< ***
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] 6 thread(s) found on [[simple:Wikipedia:Change filter/Mistakes]]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] No thread is old enough. Skipping
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job]
2025-11-03T17:39:00Z [bot873-wp-archive-test-b7n9h] [job] Execution time: 10 seconds
2025-11-03T17:38:54Z [bot873-wp-archive-test-b7n9h] [job] WARNING: API warning (result): This result was truncated because it would otherwise be larger than the limit of 12,582,912 bytes.

Moot point now. I've retired the bot since I don't really have time to maintain it anymore. I'll leave the issue open for shiggles and answer whatever questions I can.

Change #1201088 merged by Xqt:

[pywikibot/core@master] [IMPR] respect the ``-namespace`` option with ``-page`` option

https://gerrit.wikimedia.org/r/1201088

I run an archive bot on Chinese Wikipedia and have the same issue. I fail to understand why authentication is required when archivebot.py tries to access the contents of Q6068612 and Q6723402 on wikidata (https://gerrit.wikimedia.org/r/plugins/gitiles/pywikibot/core/+/HEAD/scripts/archivebot.py#227) which is publicly available.