fix(bootstrap): retry transient network failures during install#165
Merged
jh-lee-cryptolab merged 1 commit intoJun 9, 2026
Merged
Conversation
The install bootstrap chain had no retry anywhere, so a single transient GitHub CDN failure (e.g. a 504) aborted the whole install. This adds bounded exponential-backoff retry to every blocking fetch in the rune CLI bootstrap, matching the convention already used by runed's downloadWithRetry. - bin/rune: add `--retry 3 --retry-delay 2` to the version-lookup and binary/checksums curls so a transient CDN blip is ridden out. - internal/bootstrap: add a shared withRetry helper (3 attempts, backoff 2s -> 6s -> 18s, ctx-cancel aware) and wrap artifact downloads (DownloadAndVerify) and the manifest fetch. Only the network fetch is retried; deterministic parse/version errors fail fast. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
couragehong
approved these changes
Jun 9, 2026
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.
Summary
bin/runeshell + Gointernal/bootstrap).bin/rune:--retry 3 --retry-delay 2on the latest-release lookup curl and the binary/checksums.txtdownload curls.internal/bootstrap/download.go: new sharedwithRetryhelper (3 attempts, backoff 2s → 6s → 18s, aborts immediately onctxcancellation).internal/bootstrap/install.go: artifact downloads (DownloadAndVerify, raw + tarball) now go throughwithRetry;logfis threaded so retries are visible in install logs.internal/bootstrap/manifest.go: manifest fetch now retries the network GET viawithRetry. Body parse / version checks stay outside the retry so deterministic errors fail fast.runedalready rides these out viadownloadWithRetry; the rune CLI did not. This closes that asymmetry.Validation
go build ./...,go vet ./internal/bootstrap/,go test ./internal/bootstrap/all pass. AddedTestFetchManifest_RetriesTransient(two 504s then success) and confirmed the existing 404 test still fails fast.bash -n bin/runepasses.Cross-Agent Invariants
codex mcp ...) are clearly separated from cross-agent/common instructionsSKILL.md,commands/rune/*.toml, andAGENT_INTEGRATION.mdstay consistent on boundariesNotes for Reviewers
varso tests compress it; manifest parse errors are deliberately not retried.FetchManifestandinstallArtifactsignatures gained alogf func(string, ...any)param (internal package only); all call sites updated.rune-admin/install.shversion-lookup curls, and optional mirror/fallback-URL support, are tracked separately.