Conversation
…backoff Found by live acceptance: one hour after serve start, every GitHub API call began failing 401 'Bad credentials' — the installation client was built once with a fixed personal_token (installation tokens expire after 1h) and never refreshed, silently wedging mention resolution, reactions, and the write outbox. The client now uses octocrab's installation auth state, which caches and refreshes tokens with an expiry buffer. Also: mention-authority resolution retried every 250ms tick on persistent failure (~4 rps against a dead credential); it now backs off exponentially (2s doubling to a 60s cap) and stops iterating the batch on first error.
Owner
Author
|
Superseded: commit cherry-picked into #142 (single acceptance-fix PR). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Found by live acceptance on v0.3.0: after the installation token expired (1h), all GitHub API calls failed 401 permanently (401 → outbox 'rejected', mentions never resolved) until restart, plus a ~4rps hot retry loop. Fix: build the installation client via
app.installation(id)(octocrab CachedToken auto-refresh) and add exponential backoff to mention-authority resolution. Verified: fmt/check/clippy/test green.