Repository navigation
fix(release): retry downloads that GitHub answers with a 5xx - #672
Open
ion-alpha-dev wants to merge 1 commit into
Open
ion-alpha-dev wants to merge 1 commit into
ion-alpha-dev wants to merge 1 commit into
Conversation
The v0.2.0 release run's Windows upgrade leg failed in 16 seconds because GitHub's release download host returned 504 for one of v0.1.3's assets. For about an hour it answered 504 for one asset at a time while serving the others, with no incident on its status page. The upgrade itself was fine: run by hand it passed. curl's --retry already treats 408, 429, 5xx and timeouts as transient, so the downloads in dev/upgrade-check, dev/container-profiles and install.sh's curl path now retry five times. The wget path in install.sh is unchanged because busybox wget has no retry option, and install.ps1 is unchanged because Windows PowerShell 5.1's Invoke-WebRequest has no retry parameter. Signed-off-by: Ion Alpha <contact@ionalpha.io>
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
What
The downloads in
dev/upgrade-check,dev/container-profilesandinstall.sh's curl path now pass--retry 5 --retry-delayso a transient answer from GitHub (408, 429, 5xx, a timeout) is retried instead of failing the job or the install.Why
The v0.2.0 release run's Windows upgrade leg failed in 16 seconds on
curl: (22) The requested URL returned error: 504while downloading v0.1.3's assets, before it tested anything. For about an hour GitHub's release download host returned 504 for one v0.1.3 asset at a time while serving the others, and its status page showed no incident. The upgrade itself was fine: done by hand on Windows, v0.1.3 upgraded itself to v0.2.0 and reopened its data directory.How to verify
curl -fsSL --retry 5 --retry-delay 1made three requests and exited 0 with the body../dev/upgrade-check v0.2.0 v0.1.3from this branch on Windows:ok: v0.1.3 upgraded itself to v0.2.0 on windows/amd64 and opened its data directory.sh -npasses on all three scripts and their executable bits are unchanged.Notes for reviewers
--retryhas been in curl since 7.12, so no installer user needs a newer curl.--retry-all-errorswould need 7.71 and is not used.install.shis unchanged because busybox wget has no retry option.install.ps1is unchanged because Windows PowerShell 5.1'sInvoke-WebRequesthas no retry parameter; a retry loop there can be its own change if it proves needed.