Skip to content

v2.2.0

Choose a tag to compare

@github-actions github-actions released this 21 Oct 09:01
· 218 commits to main since this release

What's new

  • Quota sidebar on OpenCode 2. OpenCode 2 now shows the same Claude quota sidebar as OpenCode 1: 5-hour, 7-day and model bars per account, routing, cache, Prime and health, in your theme's colors and configured by the same anthropic-auth entry in tui-preferences.jsonc. It reads the account pool through the plugin, with no extra file and no credentials. Thanks to @TodoniK for the contribution.
  • Claude no longer repeats a long reply after housekeeping. When Claude finished a long reply and then updated a board or tidied its context in the same step, it often wrote the reply again on the next step. After such a reply, the plugin now adds a short instruction that applies to that one step only, telling Claude the reply has already reached you. The tools it applies to are set by turnEndNote.tools (default board and ctx_reduce; an empty list turns it off). It applies to signed-in Claude accounts on Fable 5.1, Opus 5.5, Sonnet 5.5 and Haiku 5.5, and earlier instructions are re-sent unchanged so the prompt cache isn't rebuilt.

What's fixed

  • A finished login renewal no longer fails the request. If a background quota check finished while a login was being renewed, the renewal could report failure even though the new token was already saved. OpenCode 1 then kept a 401, OpenCode 2 gave up its retry and Pi ended the reply with an error. The saved token was never lost; the next request used it.
  • A valid login no longer waits for a background renewal. A request whose token was still valid could wait behind a renewal already running for the same account. It is now sent at once. A request whose token Anthropic just rejected waits at most two seconds for the new one, then fails with a retryable error, and the rejected token is never sent again.
  • Fewer usage calls after insula restarts (vault mode). While insula is starting up, or Anthropic is already rate-limiting it for an account, the plugin no longer asks Anthropic for that account's usage itself. It still asks when insula is unreachable, can't use the login, or has no current reading.
  • Before an account has served a session, the collapsed sidebar no longer marks main as active.

Dependencies

  • @cortexkit/common-auth 0.22.0. OpenTUI 0.6.6 and the OpenCode 2 plugin SDK 2.0.32, each moved as one family so a single copy installs.

To upgrade, quit OpenCode and run npx @cortexkit/opencode-anthropic-auth@2.2.0 setup, or change the version in your OpenCode config.