v0.3.32: Honor Retry-After on HTTP 429 and add jittered exponential backoff #27
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
gitea_auth.api_requestis the single HTTP entry point for all Gitea API calls. It has no retry handling: a transient HTTP 429 (rate limit) fails immediately withRuntimeError.Goal
When an upstream API call returns HTTP 429,
api_requestshould:Retry-Afterwhen present.Retry-Aftervalues.Retry-Afteris missing or invalid.Acceptance criteria
Retry-After(seconds and HTTP-date).Retry-Afteruses capped jittered exponential backoff.Branch:
fix/v0.3.32-retry-after-backoff