jenkins-bot has submitted this change and it was merged.
Change subject: [FIX] Tokens: Fix getting tokens with the new scheme ......................................................................
[FIX] Tokens: Fix getting tokens with the new scheme
Change-Id: I5b79d02edaf19724ec9c8857f33c57683edb9da6 --- M pywikibot/site.py 1 file changed, 5 insertions(+), 5 deletions(-)
Approvals: John Vandenberg: Looks good to me, approved jenkins-bot: Verified
diff --git a/pywikibot/site.py b/pywikibot/site.py index 1a16e06..6e41cc2 100644 --- a/pywikibot/site.py +++ b/pywikibot/site.py @@ -2281,13 +2281,13 @@ type='|'.join(types)).submit() else: # TODO: Fetch that from the API with paraminfo - special_names = set('deleteglobalaccount', 'patrol', 'rollback', - 'setglobalaccountstatus', 'userrights', - 'watch') + special_names = set(['deleteglobalaccount', 'patrol', 'rollback', + 'setglobalaccountstatus', 'userrights', + 'watch']) new_tokens = [token if token in special_names else 'csrf' for token in types] - data = api.Request(action='query', - tokens='|'.join(new_tokens)).submit() + data = api.Request(action='query', meta='tokens', + type='|'.join(new_tokens)).submit() if 'query' in data: data = data['query']
pywikibot-commits@lists.wikimedia.org