fix(server): only run provider updates through the installer that owns the binary (#9325)
Co-authored-by: Claude Code <[email protected]>
This commit is contained in:
1 parent
94cc8152ff
commit
2fb99a7a66
23 files changed
+1642
-954
No files matched your search
@@ -55,6 +55,25 @@ run before the prompt. They reject profiles with such configuration before launc
|
||||
instructions and tool denial do not create a native sandbox.
|
||||
See [helper constraints](../../apps/server/src/textGeneration/AntigravityTextGeneration.ts).
|
||||
|
||||
## Provider updates run only through the owning installer
|
||||
|
||||
A one-click update is offered only when the resolved executable's path proves which installer owns
|
||||
it. Homebrew and npm are proven by the real path (symlinks followed): a versioned keg or cask under
|
||||
`brew --prefix`, or `<prefix>/lib/node_modules/<pkg>/` (Windows: the shim beside `node_modules`).
|
||||
Native installer layouts and the global bin directories of pnpm, Bun, and Vite+ may match on either
|
||||
the resolved path or its real target, since those installers place real files or their own symlinks
|
||||
there. Anything unproven stays manual-only but still reports the version gap. npm updates pin
|
||||
`--prefix` because the `npm` on `PATH` can belong to a different Node than the one that owns the
|
||||
provider. Homebrew
|
||||
compares against `brew info` since casks trail npm by hours; native installs share npm's version
|
||||
train, so the registry stays authoritative for them.
|
||||
See the [resolver](../../apps/server/src/provider/providerMaintenance.ts).
|
||||
|
||||
Ownership is cached per instance and re-read immediately before an update runs. The
|
||||
[runner](../../apps/server/src/provider/providerMaintenanceRunner.ts) refuses when the lock key
|
||||
changed since the advisory, and reports success only when the refreshed provider is still installed
|
||||
with a readable, current version.
|
||||
|
||||
## Protocol traps
|
||||
|
||||
Codex async questions arrive as notifications and are answered with a new user message. There is
|
||||
|
||||
@@ -81,6 +81,13 @@ Provider CLIs must be on the server's `PATH`. If T3 Code cannot find one, set it
|
||||
Cursor's executable is `cursor-agent`, although its login command is
|
||||
`agent login`. Antigravity can use its managed runtime without a `PATH` entry.
|
||||
|
||||
When a provider CLI is behind its latest release, its provider card shows the
|
||||
available version. **Update now** appears only when T3 Code can tell which
|
||||
installer owns the CLI (its own update command, Homebrew, or a global npm, pnpm,
|
||||
bun, or Vite+ install) and runs that installer. Otherwise update the CLI the same
|
||||
way you installed it. Homebrew installs compare against the version Homebrew
|
||||
offers, which can trail the npm release by a few hours.
|
||||
|
||||
Add another provider instance for a separate account or configuration. Each
|
||||
instance can have its own environment variables, such as API keys or a custom
|
||||
base URL. Mark secret values as sensitive; after saving, T3 Code does not display
|
||||
|
||||
Reference in new issue
Block a user