Retry push and release notifications after a Discord rate limit #25

Open
github-bot wants to merge 1 commit from github-bot/gh-25 into main AGit
Owner

@⁠RavenCurseBurg on GitHub · 2026-11-26 03:27 UTC · original
RavenCurseBurg:fix/discord-rate-limit → main · +75 −10 · 2 files · 1 commits · open

A webhook that returned HTTP 429 caused the notifier to exit immediately, even when Discord specified when the message could be retried. The notifier now honors Retry-After or a fractional retry_after in the JSON body. It makes at most three attempts and reports the error when the requested wait exceeds 60 seconds. Other HTTP and transport errors keep their existing behavior. Discord rate-limit response

The new regression tests cover header and JSON delays, repeated 429s and unusable delays. On the base revision the header and JSON cases both exited at the first 429. All 47 Python tooling tests and all three warnings-as-errors Release CTests passed with the change. A loopback HTTP server returned 429 then 204 and received the same synthetic payload twice, 52 ms apart for a 50 ms requested delay. All tests ran without a Discord webhook.

AI-assisted with Codex + GPT-6.2 Astra (xhigh).

**@⁠RavenCurseBurg** on GitHub · 2026-11-26 03:27 UTC · [original](https://github.com/JamesCicada/GTAVI-Recomp/pull/25) `RavenCurseBurg:fix/discord-rate-limit` → `main` · +75 −10 · 2 files · 1 commits · open A webhook that returned HTTP 429 caused the notifier to exit immediately, even when Discord specified when the message could be retried. The notifier now honors `Retry-After` or a fractional `retry_after` in the JSON body. It makes at most three attempts and reports the error when the requested wait exceeds 60 seconds. Other HTTP and transport errors keep their existing behavior. [Discord rate-limit response](https://docs.discord.com/developers/topics/rate-limits#exceeding-a-rate-limit) The new regression tests cover header and JSON delays, repeated 429s and unusable delays. On the base revision the header and JSON cases both exited at the first 429. All 47 Python tooling tests and all three warnings-as-errors Release CTests passed with the change. A loopback HTTP server returned 429 then 204 and received the same synthetic payload twice, 52 ms apart for a 50 ms requested delay. All tests ran without a Discord webhook. AI-assisted with Codex + GPT-6.2 Astra (xhigh).
AI-assisted with Codex + GPT-6.2 Astra (xhigh).
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 20:44:38 +00:00
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/25/head:github-bot/gh-25'
git switch 'github-bot/gh-25'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-25'
git switch 'github-bot/gh-25'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-25'
git switch 'github-bot/gh-25'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-25'
git switch 'main'
git merge --squash 'github-bot/gh-25'
git switch 'main'
git merge --ff-only 'github-bot/gh-25'
git switch 'main'
git merge 'github-bot/gh-25'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.