Page MenuHomePhabricator

automatic login to private wiki raises APIError on the second failed login
Closed, InvalidPublic

Description

If an automatic login to a private (read denied) is attempted twice, the first action will raise NoUsername, but the second login will raise APIError.

Event Timeline

jayvdb created this task.Jun 1 2015, 6:08 AM
jayvdb raised the priority of this task from to High.
jayvdb updated the task description. (Show Details)
jayvdb added subscribers: Unknown Object (MLST), jayvdb, Aklapper.
XZise added a subscriber: XZise.Jun 1 2015, 9:52 AM

I'm currently guessing but it does sort of make sense. The second APIError happens probably because after the first failed login the API knows that login doesn't work and doesn't attempt to login but just reraises the possible APIError caught in the first attempt.

XZise added a comment.EditedJun 1 2015, 10:31 AM

Ah the site's _loginstatus is -2 (IN_PROGRESS). Seems like the status is not properly changed.

Change 215000 had a related patch set uploaded (by XZise):
[FIX] APISite: Reset loginstatus

https://gerrit.wikimedia.org/r/215000

XZise claimed this task.Jun 1 2015, 11:02 AM

Change 143038 had a related patch set uploaded (by John Vandenberg):
site._loginstatus - login process and caching

https://gerrit.wikimedia.org/r/143038

D3r1ck01 moved this task from Backlog to Needs Review on the Pywikibot board.Nov 5 2018, 11:36 AM
Xqt removed XZise as the assignee of this task.Mar 31 2020, 3:47 PM
Huji closed this task as Invalid.May 11 2020, 2:59 PM
Huji added a subscriber: Huji.

Judging by the associated patch, this was related to the "sysopnames" feature of bot logins, which we have since deprecated and removed (see T71283). I am going to mark it as Invalid given how much the code has moved forward since this task was created. Can always be reopened if the issue still matters.

Dvorapa added a subscriber: Dvorapa.EditedMay 11 2020, 3:30 PM

I can see only a little sysopnames connection here or in the patch. The whole point is resetting the login status on failure, which is a clever idea. But anyway issues like these are still present, but the output changed since then drastically so it would be hard to recognize the newly occuring issue is a dupe of this one.

Change 143038 abandoned by Xqt:
site._loginstatus - login process and caching

Reason:
very outdated

https://gerrit.wikimedia.org/r/143038

Change 215000 abandoned by Xqt:
[FIX] APISite: Reset loginstatus

Reason:
already solved

https://gerrit.wikimedia.org/r/215000