Page MenuHomePhabricator

Compat login broken. KeyError: 'lgtoken'
Closed, DeclinedPublic


Traceback (most recent call last):
  File "C:\Python27\pywikipedia\", line 475, in <module>
  File "C:\Python27\pywikipedia\", line 470, in main
  File "C:\Python27\pywikipedia\", line 344, in login
    cookiedata = self.getCookie(api)
  File "C:\Python27\pywikipedia\", line 258, in getCookie[index] = data['login']['lgtoken'] + "+\\"
KeyError: 'lgtoken'

Related Objects

Event Timeline

XXN triaged this task as Unbreak Now! priority.Nov 13 2016, 5:00 PM
Xqt lowered the priority of this task from Unbreak Now! to High.Nov 13 2016, 5:21 PM

Decreasing prio because compat is a deprecated branch.

API changes in 1.28:

  • The following response properties from action=login, deprecated in 1.27, are now removed: lgtoken, cookieprefix, sessionid. Clients should handle cookies to properly manage session state.
  • Submitting the lgtoken and lgpassword parameters in the query string to action=login is now deprecated and outputs a warning. They should be submitted in the POST body instead.

(imho: better one merge to the core branch instead of investigating into this stuff)

Declined due to decommission compat