You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: upgrade notification silently skipped in multiple scenarios (#389)
* fix: upgrade notification silently skipped in multiple scenarios
The upgrade indicator was never shown when:
- `autoupdate` was `false` or `OPENCODE_DISABLE_AUTOUPDATE` was set
- Install method was `"unknown"` or `"yarn"`
- Auto-upgrade failed (error swallowed by `.catch(() => {})`)
Additionally, there was no guard against downgrading canary/preview users
to an older stable release.
Changes:
- Always publish `UpdateAvailable` event so the indicator and toast appear
- Add `semver.gte()` guard to prevent downgrades
- Add `log.warn()` for `latest()` fetch failures and auto-upgrade errors
- Handle `yarn` install method explicitly (detected but not auto-upgradeable)
- Add 34 tests covering every decision path in `upgrade()`
- Update docs: clarify `autoupdate` config values, add upgrade indicator note
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: pre-existing typecheck errors in `training-import.test.ts`
- `readFile` mock return type mismatch (string vs Buffer)
- `count` mock missing `context` and `rule` keys
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: wire up `ALTIMATE_CLI_DISABLE_AUTOUPDATE` env var using `altTruthy`
The documented env var `ALTIMATE_CLI_DISABLE_AUTOUPDATE` was not functional —
`flag.ts` only read the legacy `OPENCODE_DISABLE_AUTOUPDATE`. Updated to use
`altTruthy()` pattern matching other flags in the codebase.
Found during multi-model code review (GPT 5.2 Codex, Gemini 3.1 Pro).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|`autoupdate`|`boolean \| "notify"`| Auto-update behavior: `true` (default) auto-upgrades, `"notify"` shows an indicator without upgrading, `false` disables auto-upgrade but still shows the update indicator|
48
48
|`provider`|`object`| Provider configurations (see [Providers](providers.md)) |
49
49
|`mcp`|`object`| MCP server configurations (see [MCP Servers](mcp-servers.md)) |
50
50
|`formatter`|`object \| false`| Formatter settings (see [Formatters](formatters.md)) |
0 commit comments