Sannita created this task.
Sannita added a project: Pywikibot-login.py.
Restricted Application added subscribers: pywikibot-bugs-list, Aklapper.
Restricted Application added a project: Pywikibot.
TASK DESCRIPTION
I tried after several years to use again the pywikibot framework. After
downloading Python 3.9 + pip + lastest stable version of pywikibot, I managed
after several attempts to configure my user file, and saved my password on a
separate file.
Then when I tried to run the "py pwb.py login" command, the following
happened:
WARNING: No user is logged in on site wikipedia:it
Logging in to wikipedia:it as SanniBot@BotPasswordName
Traceback (most recent call last):
File "c:\Users\Utente\Desktop\pywikibot\pwb.py", line 363, in <module>
if not main():
File "c:\Users\Utente\Desktop\pywikibot\pwb.py", line 355, in main
run_python_file(filename,
File "c:\Users\Utente\Desktop\pywikibot\pwb.py", line 74, in
run_python_file
exec(compile(source, filename, 'exec', dont_inherit=True),
File ".\scripts\login.py", line 190, in <module>
main()
File ".\scripts\login.py", line 172, in main
site.login(autocreate=autocreate)
File "c:\Users\Utente\Desktop\pywikibot\pywikibot\tools\__init__.py",
line 1449, in wrapper
return obj(*__args, **__kw)
File "c:\Users\Utente\Desktop\pywikibot\pywikibot\site\__init__.py", line
1515, in login
if login_manager.login(retry=True, autocreate=autocreate):
File "c:\Users\Utente\Desktop\pywikibot\pywikibot\login.py", line 326, in
login
cookiedata = self.getCookie()
File "c:\Users\Utente\Desktop\pywikibot\pywikibot\tools\__init__.py",
line 1532, in wrapper
return obj(*new_args, **new_kwargs)
File "c:\Users\Utente\Desktop\pywikibot\pywikibot\data\api.py", line
3053, in getCookie
and (response['messagecode'] == 'login-throttled'
KeyError: 'messagecode'
CRITICAL: Exiting due to uncaught exception <class 'KeyError'>
Since I double-checked the password, I think the problem is within the
password file and/or there is a wrong configuration of the PATH file. Or is it
something else?
TASK DETAIL
https://phabricator.wikimedia.org/T269503
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: Sannita
Cc: Aklapper, pywikibot-bugs-list, Sannita, JohnsonLee01, SHEKH, Dijkstra,
Khutuck, Zkhalido, Viztor, Wenyi, Tbscho, MayS, Mdupont, JJMC89, Dvorapa,
Altostratus, Avicennasis, mys_721tx, jayvdb, Masti, Alchimista, Rxy
_______________________________________________
pywikibot-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs