Omegat added a comment.
This changeset was reverted by xzise in https://gerrit.wikimedia.org/r/#/c/182168/
As pointed out by xzise, test_token passed for a particular case before merging the change 181883. https://travis-ci.org/wikimedia/pywikibot-core/jobs/45416313#L801
While test_token was skipped when it was run on the change 181883. https://travis-ci.org/wikimedia/pywikibot-core/jobs/45420743#L800
This happened so because TokenWallet.__contains__ (key in site.tokens; gets underlined due to double underscore) only returns token value of a cached token. While TokenWallet.__getitem__ (token = site.tokens[key]) requests for the required token (if the token is not available in cache).
TASK DETAIL https://phabricator.wikimedia.org/T85353
REPLY HANDLER ACTIONS Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: Omegat Cc: Aklapper, jayvdb, XZise, Omegat, pywikipedia-bugs