Repository navigation
Keep upgrades working through the repo's move between orgs - #185
Merged
Merged
Conversation
The release lookup read only the first Location off /releases/latest and expected it to name a tag. Once the repo moves to BuildwithGusto, that first hop is the move's own redirect, so every installed binary would fail with release_lookup_failed. The old path's redirects also stop working some time after the move. - Look for releases under BuildwithGusto/gusto-cli first, then Gusto/gusto-cli, so a binary finds them before the move, during the redirect window, and after the redirects lapse. - Follow a short, https-only redirect chain until a Location names a release tag. - Download from the repo the tag was found in, so nothing after the lookup depends on a redirect. A pinned GUSTO_CLI_VERSION has no lookup, so its download tries each repo in turn, with SHA256SUMS always from the repo that served the binary. - Only an HTTP answer moves on to the next repo. A network error or timeout would fail the same way again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Jeff Stephens <jeff.stephens@gusto.com>
jcraigk
approved these changes
Oct 27, 2026
10 tasks done
jeff-gusto
added a commit
that referenced
this pull request
Oct 28, 2026
## Summary - Bumps the root package version and public version examples from `0.4.0` to `0.5.0`. - Prepares `v0.5.0` for the missing-scope error changes (#182) and the upgrade changes that keep `gusto upgrade` and auto-update working through the repo's move between orgs (#185). The upgrade change only reaches installed binaries once they update to a release that contains it, so this should be released promptly. ## Linked issue None. ## Test plan - [x] `env -u NO_COLOR bun run test:all` passes locally - [x] Manual run of touched commands works against sandbox — not applicable; this changes only version metadata and documentation - [x] `--agent` and `--human` output verified where touched — not applicable; this changes no output behavior - [x] `tsc --noEmit` - [x] `bun run lint` - [x] `bun run format:check` - [x] `bun run license:check` - [x] `bun run build` - [x] Compiled binary reports `0.5.0` ## DCO - [x] Every commit is signed off (`git commit -s`) per the [DCO](https://github.com/Gusto/gusto-cli/blob/main/CONTRIBUTING.md#developer-certificate-of-origin) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Signed-off-by: Jeff Stephens <jeff.stephens@gusto.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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
Gusto/gusto-clitoBuildwithGusto/gusto-cli. The upgrade's release lookup read only the firstLocationoff/releases/latestand expected it to name a tag. After the move, that first hop is the move's own redirect, so every installed binary would fail withrelease_lookup_failed. The old path's redirects also stop working some time after the move.gusto upgradeand background auto-update now look for releases underBuildwithGusto/gusto-clifirst, thenGusto/gusto-cli. A binary from this release on finds releases before the move, while the old path redirects, and after the redirects lapse.GUSTO_CLI_REPOstill overrides this with one repo.Locationnames a release tag. The download then comes from the repo the tag was found in, so nothing after the lookup depends on a redirect.GUSTO_CLI_VERSIONhas no lookup, so its download tries each repo in turn.SHA256SUMSalways comes from the repo that served the binary.Binaries released before this change can't be fixed in place. They keep upgrading only if they pick up this release before the move, so it should ship soon.
Not in this PR:
install.sh, thecli.gusto.com/install.shredirect, the help text and the README at the new repo. That follows the move.Gusto/gusto-clifrom the list of repos to try, once every supported release looks under the new name first.Linked issue
None.
Test plan
bun run test:allpasses locallyBuildwithGusto/gusto-clireturned 404, the lookup fell back toGusto/gusto-cli, and it resolvedv0.4.0with downloads from that repo.--agentand--humanoutput verified where touched: not applicable, since the envelope shape is unchanged. Only error messages and a stderr log line differ.bun run lint,tsc --noEmit,bun run format:checkLocation, refusing an http redirect, a redirect loop, no fallback on a network error, the pinned download fallback (checksum included), and downloading only from the repo the lookup found.DCO
git commit -s) per the DCO🤖 Generated with Claude Code