backnotprop / backnotprop/plannotator
chore(opencode): move V2 adapter to the stable plugin API
- Dominant language
- TypeScript
- Stars
- 8.7k
- Forks
- 649
- Avg merge
- 11h 12m
- Merged PRs (30d)
- 109
Description
The OpenCode 2 adapter added in #1194 currently pins a matching `next` release of `@opencode-ai/plugin` and excludes its five-package V2 dependency family from Bun's seven-day release-age gate.
The current stable package, `@opencode-ai/plugin@1.18.13`, exposes `Plugin.define` through `@opencode-ai/plugin/v2/promise`, but that version's plugin context does not include the `session` or `tool` domains required for Plannotator's context transformation and `submit_plan` registration. It therefore cannot replace the pinned nightly yet.
When those APIs reach a stable release:
- Move the OpenCode 2 adapter to the stable plugin export.
- Revisit the V1 build boundary so `dist/index.js` does not bake the nightly `/v1` helper into the published bundle when a stable equivalent is available.
- Remove the `@opencode-ai/ai`, `@opencode-ai/client`, `@opencode-ai/plugin`, `@opencode-ai/protocol`, and `@opencode-ai/schema` release-age exclusions from `bunfig.toml`.
- Update the installed-package CI smoke to the matching stable `opencode2` release.
- Re-run the OpenCode 1 package-boundary coverage and the real OpenCode 2 packed-package smoke.
Follow-up to #904 and #1194.
Contributor guide
Assessment
This issue has not been assessed yet.