Page MenuHomePhabricator

retry-after value retrieved from http header looks wrong
Open, HighPublic

Description

With T144023 we introduced using 'retry-after' value from http response_headers.

But sometimes the maxlag value is very high compared to the retry_after value which might to short:
see https://api.travis-ci.org/v3/job/458291459/log.txt for example (T210322)

See also https://www.mediawiki.org/w/index.php?title=Manual:Maxlag_parameter&oldid=85948
Refer T172293 too.

Event Timeline

Xqt created this task.Nov 28 2018, 1:57 PM
Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. · View Herald TranscriptNov 28 2018, 1:57 PM
Xqt triaged this task as High priority.Nov 28 2018, 1:57 PM

Change 476274 had a related patch set uploaded (by Xqt; owner: Xqt):
[pywikibot/core@master] [bugfix] Increase the delay if maxlag >> retry-after

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

Xqt updated the task description. (Show Details)Nov 28 2018, 2:41 PM

I wonder if @Anomie has any input on this.

Getting a better estimate for Retry-After is T172293. This doesn't seem to really be a bug other than that existing feature request.

Xqt added a comment.Nov 30 2018, 11:34 AM

My path above is a proposal to use a portion of maxlag parameter as a prediction for the next lag if retry_after is far away from maxlag.

Xqt added a comment.EditedNov 30 2018, 11:36 AM
retry_after maxlagwait time
5105
5306
55010
510020
525050
51000120
55000120
D3r1ck01 moved this task from Backlog to Needs Review on the Pywikibot board.Dec 22 2018, 6:16 PM
Xqt claimed this task.Feb 7 2019, 4:28 PM