Skip to content

gh-prs-merge: wait out a spent GitHub rate limit, and fail loudly past it (0.68.3) - #191

Merged
ralyodio merged 1 commit into
masterfrom
fix/prs-merge-rate-limit
Oct 19, 2026
Merged

ralyodio merged 1 commit into
masterfrom
fix/prs-merge-rate-limit

Conversation

@ralyodio

Copy link
Copy Markdown
Contributor

A rate-limited gh search prs was reported as "skipped inaccessible or
invalid scope", every scope warned, nothing was found, and the run printed an
all-zero summary with exit 0: a sweep that did nothing, reported as a sweep
with nothing to do.

Gh now recognises GitHub's primary and secondary rate-limit refusals, reads
the reset from gh api rate_limit (free, answers while everything else is
refused), and waits it out when it is within --rate-wait (default 900s),
then retries. A reset further off throws RateLimitError, which the sweep
counts as FAILED for that scope, so the run exits 1 and says when to retry.

🤖 Generated with Claude Code

…t it (0.68.3)

A rate-limited `gh search prs` was reported as "skipped inaccessible or
invalid scope", every scope warned, nothing was found, and the run printed an
all-zero summary with exit 0: a sweep that did nothing, reported as a sweep
with nothing to do.

Gh now recognises GitHub's primary and secondary rate-limit refusals, reads
the reset from `gh api rate_limit` (free, answers while everything else is
refused), and waits it out when it is within --rate-wait (default 900s),
then retries. A reset further off throws RateLimitError, which the sweep
counts as FAILED for that scope, so the run exits 1 and says when to retry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ralyodio
ralyodio merged commit 8ab7b93 into master Oct 19, 2026
4 checks passed
@github-actions

Copy link
Copy Markdown

ThreatCrush Security Scan

33 finding(s)

HIGH/CRITICAL: 7 | MEDIUM: 12 | LOW: 14

Severity Rule Location
HIGH py-ssrf-outbound-request dev2/dev2-site:151
HIGH py-ssrf-outbound-request dev2/dev2-site:1060
HIGH py-ssrf-outbound-request dev2/dev2-site:1775
HIGH sh-remote-script-execution root-ubuntu.sh:3250
HIGH sh-remote-script-execution root-ubuntu.sh:3251
HIGH sh-remote-script-execution root-ubuntu.sh:5146
HIGH sh-remote-script-execution root-ubuntu.sh:5150
MEDIUM sql-template-interpolation dev2/dev2-site:1286
MEDIUM sql-template-interpolation dev2/dev2-site:1363
MEDIUM sh-remote-script-execution root-ubuntu.sh:5354
MEDIUM redos-nested-quantifier src/domain-free.ts:56
MEDIUM redos-nested-quantifier src/emoji.ts:167
MEDIUM redos-nested-quantifier src/icon.ts:166
MEDIUM redos-nested-quantifier src/mail.ts:1047
MEDIUM sql-template-interpolation src/users-dump.ts:487
MEDIUM sql-string-concatenation src/users-dump.ts:507
MEDIUM sql-template-interpolation src/users-dump.ts:540
MEDIUM sql-string-concatenation src/users-dump.ts:574
MEDIUM redos-nested-quantifier src/wcag.ts:556
LOW secret-generic-credential src/credentials.ts:36
LOW secret-generic-credential src/credentials.ts:53
LOW secret-generic-credential src/credentials.ts:56
LOW secret-generic-credential src/credentials.ts:61
LOW secret-generic-credential src/user-export.ts:689
LOW secret-generic-credential src/user-export.ts:695
LOW secret-generic-api-key test/credentials.test.ts:208
LOW secret-generic-credential test/mail.test.ts:141
LOW secret-generic-credential test/proxy.test.ts:69
LOW secret-generic-credential test/proxy.test.ts:85
LOW secret-generic-credential test/shorten.test.ts:36
LOW secret-database-url test/users-dump.test.ts:108
LOW secret-database-url test/users-dump.test.ts:119
LOW secret-database-url test/users-dump.test.ts:120

Snippets are redacted; ThreatCrush never prints matched credential material.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant