Skip to content

chore: version packages#129

Merged
iceglober merged 1 commit into
mainfrom
changeset-release/main
Apr 26, 2026
Merged

chore: version packages#129
iceglober merged 1 commit into
mainfrom
changeset-release/main

Conversation

@harness-opencode-ci

Copy link
Copy Markdown
Contributor

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

@glrs-dev/harness-opencode@0.16.2

Patch Changes

  • #128 3f34e76 Thanks @iceglober! - Fix pilot build stalling with "0 events" at 5min.

    Two independent bugs that both blocked pilot from ever running:

    1. Pilot's opencode server had no pilot-builder / pilot-planner
      agents.
      opencode serve (spawned by the SDK's
      createOpencodeServer) does not load external plugins — only the
      interactive opencode TUI does. Verified via opencode serve --print-logs --log-level DEBUG: zero service=plugin lines. The
      pilot worker's session.promptAsync({ agent: "pilot-builder" })
      was accepted by the server but the prompt went nowhere, because
      no agent was registered under that name. Fix: inject the two
      pilot agents into the spawned server's config via the SDK's
      createOpencodeServer({ config }) option (forwarded to the server
      as OPENCODE_CONFIG_CONTENT env var).

    2. EventBus received only server-wide events (heartbeats,
      file-watcher), never session-level events.
      opencode's SSE
      /event endpoint scopes session events (message.updated,
      message.part.updated, session.idle) by subscriber directory, and
      the match is exact, not prefix. The EventBus was constructed
      once per run without a directory, so the SSE stream dropped every
      session event the server published. Verified empirically: a 15s
      window over a live pilot-builder session with no directory yielded
      2 events (heartbeats); with the task's exact worktree directory,
      27 events including session.idle. Fix: construct a new EventBus
      per task, scoped to the task's worktree. WorkerDeps.bus became
      WorkerDeps.busFactory: (directory: string) => EventBus.

      Also:

    • Default stallMs raised from 5min to 60min. The 5min default was
      calibrated against a broken stream — with events actually flowing,
      legitimate inter-event gaps during deep subagent work can exceed
      5min. User-override still honored.

    • New diagnostic: when PILOT_EVENT_LOG env var is set, EventBus
      dumps every raw SSE event (with extracted sessionID, live
      subscriber IDs, and matched-subscriber count) as JSONL to that
      path. Zero overhead when unset.

    • Regression tests: EventBus — directory scoping (3 tests locking
      the subscribe-call contract) and buildPilotServerConfig (4 tests
      locking the injected-agents contract).

@harness-opencode-ci harness-opencode-ci Bot force-pushed the changeset-release/main branch from 7367f0c to 2672554 Compare April 26, 2026 23:12
@iceglober iceglober merged commit d7d7977 into main Apr 26, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant