Page MenuHomePhabricator

rollback token not accessible on versions before query+tokens
Closed, InvalidPublic

Description

I'm not sure if this is a bug or a feature request but there are two different ways to get the rollback token: Since the introduction of query+tokens, it's possible via there and this is already implemented. But before that the token was associated with the revision and APISite.get_tokens does not handle that and instead errors that the rollback token is not a valid token name.

But unlike the patrol token (T85727) it seems that the rollback token is not always the same, even different between two revisions of the same page. So it seems like that site.tokens['rollback'] is impossible on older wikis and instead the library/scripts should use the revisions' rollbacktoken which itself then could request the token via site.tokens['rollback'] on newer wikis.

Event Timeline

XZise raised the priority of this task from to Needs Triage.
XZise updated the task description. (Show Details)
XZise added a project: Pywikibot.
XZise subscribed.
Restricted Application added subscribers: Aklapper, Unknown Object (MLST). · View Herald TranscriptFeb 27 2015, 12:06 PM
Xqt triaged this task as Low priority.Feb 18 2020, 5:53 PM
Xqt lowered the priority of this task from Low to Lowest.Mar 9 2020, 12:05 PM
Xqt subscribed.

which are the related mw versions?

Additional Information needed. Older MW Version < 1.19 has been dropped.