Comment

Shad Sterling

5xx error responses might include a retry-after header, which you should honor. See https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Retry-After

Replies

Peter Bengtsson

Good point! But it belongs to requests.packages.urllib3.util.retry.Retry
Do you know if it supports it already?

Shad Sterling

It shouldn't. retry-after could give you a date next week, that lib shouldn't hang your script until then.