Repository navigation
Harden git-bug sync workflow against transient failures - #3
Merged
Merged
Conversation
All 7 recent "Sync git-bug issues from GitHub" failures fall into two transient classes: - "Error: invalid parameter owner: " (Sep 5 x3, Sep 20, Sep 24): `git-bug bridge new` validates --owner with an *unauthenticated* GET api.github.com/users/<owner> (--token is not used for it). On shared runner IPs the 60 req/h anonymous quota is often exhausted, the call returns non-200 and git-bug reports an empty owner. Retry up to 5 times; when /rate_limit shows the anonymous quota is exhausted, wait for its reset (capped at 5 min), else back off. - "git-bug: line 1: <!DOCTYPE html>" (Sep 15 x2): `curl -sL` without -f saved GitHub's HTML error page as the binary. Use `curl -f` so HTTP errors fail the download (with --retry) instead of producing a bogus binary, and verify a pinned sha256 of the v0.10.1 release binary to catch any other truncated/garbled download. Also cap the job at 30 min: a run normally takes well under a minute; the cap leaves room for the rate-limit waits in "Configure bridge" but stops a wedged run from blocking the concurrency queue for hours. Bump actions/checkout to v5 in all workflows to drop the Node.js 20 deprecation warning. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Vcf1sCLxS4sABQXeYiGJen
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.
All 7 recent failures of "Sync git-bug issues from GitHub" (Aug 30 – Sep 24) fall into two transient classes; the other workflows are green.
1.
Error: invalid parameter owner:(e.g. runs 35554884094, 36000366629)git-bug bridge new(v0.10.1,bridge/github/config.go:validateUsername) validates--ownerwith an unauthenticatedGET https://api.github.com/users/<owner>—--tokenisn't used for it. Shared runner IPs often exhaust the 60 req/h anonymous quota; the call returns non-200 and git-bug reports an empty owner.Fix: retry
bridge newup to 5×. Between attempts query/rate_limit(free); if the anonymous quota is exhausted wait for its reset (capped at 5 min), otherwise back off 30s·attempt. Nothing is persisted when that check fails, so retrying is safe.2.
git-bug: line 1: <!DOCTYPE html>(run 34963196357)curl -sLwithout-fsaved GitHub's HTML error page as the binary.Fix:
curl -fsSL --retry 5 --retry-all-errorsplus sha256 verification of the pinned v0.10.1 binary.Also
timeout-minutes: 30on the sync job (normally < 1 min) so a wedged run can't hold the concurrency queue.actions/checkout@v4→@v5in all workflows (Node.js 20 deprecation warning).Testing
shellcheck; workflow YAML parses.git-bug(fail→fail→succeed; always-fail → exit 1 after 5 attempts; simulated exhausted quota → waits for reset).Residual risk: if a runner IP stays rate-limited for >~15 min the run still fails, but the next hourly run catches up. A proper upstream fix would be for git-bug to authenticate
validateUsername.🤖 Generated with Claude Code
https://claude.ai/code/session_01Vcf1sCLxS4sABQXeYiGJen
Generated by Claude Code