Skip to content

v2.0.4 - support both subscribe styles

Choose a tag to compare

@smapira smapira released this 03 Sep 14:45
· 34 commits to main since this release
Immutable release. Only release title and notes can be modified.

Fixed

  • V2 host E2E: v2Setup only handled subscribe({signal})=>AsyncIterable (promise) so opencode2 v0.0.0-beta-18999 with subscribe("session.idle")=>Stream (effect) stayed idle. Made v2Setup try both via resolveV2Iterable/trySubscribeEffect/isAsyncIterable/runV2EventLoop extracted to keep complexity <20.
  • tryCreateV2Plugin now tries both "@opencode-ai/plugin" (setup) and "@opencode-ai/plugin/effect" (effect) defines, fallback is {id, setup, effect} so both hosts pass.
  • Verified: mock effect and promise both PASS, npx eslint . 0, npx tsc --noEmit 0, bun test 85 pass, dist 24.13KB.

Full Changelog: v2.0.3...v2.0.4