Skip to content

bug: SSE event stream drops all events for worktree sessions (still present on current dev) #49861

Description

@EZotoff

Re-opening the still-relevant bug from #35917, which was auto-closed after 60 days of inactivity.

Verified today on current dev (@5f9d9187c): packages/opencode/src/server/routes/instance/httpapi/handlers/event.ts:37 still gates the SSE stream on

event.location?.directory === instance.directory &&
  (event.location.workspaceID === undefined || event.location.workspaceID === workspaceID)

Worktree sessions emit events whose location.directory differs from the main instance directory, so the directory equality check filters out every worktree event — SSE subscribers see no activity for worktree sessions at all. Original repro details are in #35917.

The prior fix PR #35913 was closed by the automated PR cleanup (>1 month old, few reviews) — not rejected on merit. A rebased version of the same two-line fix is incoming.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions