Repository navigation
feat(updates): support mise and reliable bulk cli updates - #947
Merged
Merged
Conversation
nixuuu
enabled auto-merge (squash)
November 18, 2026 07:41
nixuuu
added a commit
that referenced
this pull request
Nov 19, 2026
nixuuu
added a commit
that referenced
this pull request
Nov 19, 2026
## Problem Canopy could refuse a Claude Code update based on a saved running report, even if the worker had reconnected and had no such installation. During an actual overlap, a second click could also surface a start refusal as a failed update. The reported Nightly installer output confirms Claude Code 2.1.328 was ready on Windows. The screenshot and output do not share an attempt ID. The Windows detection change in #994 enabled the action for native installs. ## Change - Use the current worker connection for live installer status, and keep installer output with its attempt ID. - Let the worker arbitrate installs. Repeated individual requests for the same active target use the existing result. Update all reconciles an explicit busy refusal with later reports and follows the active attempt ID. An install gets its full completion window once the contention clears. - Wait for any active installer for that CLI to finish validation before treating its reported version as proof of success. The worker checks the installed version again before installing an Update all target, including when a linked snapshot is stale. The coordinator sends guarded installs only on a live link to a gateway that supports the guard. - Record the accepted attempt ID in the audit entry. ## Verification - Revision `06bb2f70` on Linux (`nix-pc`). All 86 tests passed across provider-cli, update-cli-attempts, mise-cli, update-center, update-all-computers, and cli-discovery. The test temp directory was clean. - Regression coverage includes an outdated running report, repeated requests, same-version correlation, different-version contention, a rollback-capable competing attempt a guarded stale target sent to the worker, and an older linked gateway that must receive only the ordinary unguarded request. - Generated contracts with `bun run gen`. Gateway, worker, and integration test typechecks passed. Targeted Oxlint, Oxfmt and `git diff --check` passed. - Tests exercise a real Linux worker and simulated installers. Windows execution of this revision remains unverified. ## Copy audit - Update all now tells the user to update an older worker before retrying a guarded install. If the worker cannot identify the installed CLI version, the message explains the missing version and gives the next action. An older linked gateway gets a short Canopy update instruction in the same place. - Checked both messages in the existing Updates popover against a local fixture in a desktop-width light view and a 390 px dark view with short and long worker names. The existing error control provides the full text when the compact row truncates it. Fixes: #26 Fixes: #947 Related: #994
nixuuu
added a commit
that referenced
this pull request
Nov 21, 2026
## Summary - Retry mise-managed Grok updates when the active npm package is newer than the binary its launcher runs. - Reinstall the target and allow the Grok package's setup script. Disable aube's side-effects cache for the command so setup refreshes the shared binary outside the package directory. - Support the automatically detected `latest` path when it resolves to the active global launcher. Keep the existing shim command on older mise. Fixes: #947 ## Verification - 57 tests passed in `mise-cli`, `update-cli-attempts`, and `cli-discovery` via `check:tmp`. - Worker typecheck, scoped lint, formatting, and diff check passed. - Exercised the worker installer with real mise and the published Grok package in an isolated Linux home. The same launcher reported `1.0.89` before Retry and ran the published `1.0.92` binary afterward. - Full verification runs in CI. The existing worker installation has yet to receive the patch.
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.
Change
Canopy now updates supported global mise installations of Claude Code, Codex and Grok from individual CLI controls and Update all. The recipe activates exact targets with
mise use --global --yes --pin, retains installed versions and reactivates the previous version after failed validation. Native and npm mise tool identities and customMISE_DATA_DIRroots are supported. Project overrides, multiple configured versions, fixed installation paths and mise'slatestsymlink keep manual instructions. Rollback restores an exact pin even when the previous selector floated.Update all no longer disables every CLI control in the popover. Independent targets remain actionable while their own queued/running steps, worker updates and computer restarts prevent conflicting actions. The existing four concurrent scheduler slots and per-worker installer resource locks remain in effect, including a shared mise configuration lock through rollback.
CLI steps persist an attempt UUID before dispatch and carry it through the authenticated local or linked InstallCli route. Stale failures cannot fail a new attempt, and uncertain acknowledgements wait for reports instead of failing after 60 seconds. A matching running attempt waits through validation and rollback; confirmed target or newer versions reconcile obsolete failures. Existing manual installations of the same target are followed without another command, and waiting for a different target remains bounded across gateway restarts.
The additive UI
install_idfield is opaque to computer routing; WorkerLink compatibility and the frozen UpdateService are unchanged. Older linked gateways still confirm success through the installed version, but uncorrelated failures may wait until the step timeout. Full attempt correlation requires updated gateways on both computers. Behavior and release availability are documented separately.Verification
bun run gen.check:tmpsuites passed:mise-cli,cli-discovery,provider-cli,update-cli-attempts,update-center,update-concurrency, andupdate-all-computers. Coverage includes rollback, shared resources, stale reports, lost acknowledgements, durable restart identity, owner scoping and authenticated linked routing; no temporary files remained.Fixes: #99
Fixes: #213