Repository navigation
Description
Operating system
macOS client paired to a Linux execution host.
Orca version
Execution host: 1.4.251. Client version not independently verified. The same listener gap is present on upstream/main at 586d214.
Details
A Pi worker launched inside an asynchronous pi-subagents workflow runs successfully but does not appear as a subagent in Orca's sidebar. The parent terminal says the workflow is running, while the sidebar has no corresponding worker row.
Reproduction
- Run Pi in an Orca terminal with pi-subagents 0.86.0 installed.
- Launch an asynchronous script workflow using
subagent({ workflow: "/path/to/workflow.js", async: true, args: { ... } }). - Have that script await a worker with
const result = await runs.run("example-work", { agent: "worker", model: "<configured provider/model>", task: "<task long enough to observe>" }); return result;. - While the child is working, inspect the sidebar beneath the parent agent.
Expected: the running worker appears as a child row, then stops appearing as active when it finishes.
Actual: the worker is missing even though the workflow's event log records its start and successful completion. A later worker launched through a different path did appear in the host's status snapshot, so this does not affect every subagent launch.
Evidence and likely cause
Verified the affected workflow's workspace/session association and its persisted events. It recorded a subagent.child-status event with status: "started", agent: "worker", a workflow key and a distinct childRunId, followed by subagent.workflow.child_settled with outcome: "completed".
In pi-subagents 0.86.0, src/runs/foreground/subagent-executor.js:5612-5629 builds and emits subagent:child-status for these workflow children.
Orca's src/main/pi/agent-status-subagent-roster-source.ts:87-89 subscribes to task:subagent:lifecycle, subagent:async-started and subagent:async-complete, but not subagent:child-status. The same file at line 22 deliberately excludes workflow wrappers from visible child rows. Consequently, the wrapper is hidden and the actual worker's announcement is not consumed. This is also true in the installed execution-host extension.
The likely fix belongs in the execution-host Pi status integration: consume the workflow-child lifecycle, associate the actual child with its parent, and clear it correctly on completion/failure/cancellation without exposing the wrapper or leaving stale rows. Preserve remote-host status ownership rather than inferring worker activity in the client.
Related merged work: #23201 added background child rows; #26909 improved workflow-child labels. Fresh searches found no issue or PR specifically covering this missing event subscription.
Activity
mmarabel commentedon Nov 13, 2026
Update with a live trace. The cause is not the event gap I described above: the host has every child, and what paired desktop clients receive drops them. It also affects plain
asyncsubagents, not only workflow children, and the parent row itself shows Done.What happens (host: Linux
orca serve1.4.258; client: paired macOS desktop 1.4.258; pi-subagents 0.88.1)asyncsingle runs, and oneasyncparallel workflow with 2 children.orca worktree ps --jsonis correct: the pane isworking,sidebarStatus: working,subagentObservation: live, andsubagentslists every child (4workerrows; 2scoutrows namedtask-1/task-2).Why (traced on upstream/main 048eefd; the live host data matches each step)
done.programStatusActivityreads only the root record (src/shared/program-status/activity.ts:5), so the PTY's activity becomesidleeven though thepi-subagentschild records are stillworking.pty.lastAgentStatus = 'idle'and stampslastAgentStatusRichInvalidatedAtEpochMs(src/main/runtime/terminal/output/terminal-title-observation.ts:144,:160).updatedAt…712 vs program-statusobservedAt…713 in one pane, …172 vs …174 in the other). While the Pi extension holds the turn open for children it posts nothing newer, so the hook never wins back.runtime-mobile-session-projection.ts:215) runsrenewRuntimeMobileAgentStatusFromPtyTitle(src/main/runtime/session-lifecycle/projection/runtime-mobile-agent-status-projection.ts:138-197). The hook can't own the idle title interval, so it publishesbuildTitleOnlyStatus('done', …). That entry carries nosubagents,childrenorsubagentObservation, so the client shows Done with no children.#33738 fixed the same hold in the OSC projector lane (row state). The activity lane above still reads only the root, and it is the one paired clients see.
orca worktree psreads the hook store directly, which is why it disagrees with the client.Fix direction (host side, no renderer inference): keep program activity
workingwhile a live child record of the root's program exists (the fold #33738 added toagent-status-projector.ts), or let a fresh hook status that is held open by live child work own the idle title interval inrenewRuntimeMobileAgentStatusFromPtyTitle. Either way, the published entry should keep itssubagents.No open PR touches these files.
mmarabel commentedon Nov 18, 2026
Still reproduces on newer builds: Linux
orca servehost 1.4.263, paired macOS desktop 1.4.264 (hourly), pi-subagents 0.89.0.Same pattern as the trace above: a Pi pane starts 4
asyncsubagents and ends its reply. On the host,orca worktree ps --jsonreports the worktree asworking, while the paired desktop sidebar shows the parent as Done with no child rows. This is after #38207 and #38911 merged, so neither covers this case.fix(agent-status): keep a paired host's child-held Pi row working whe…
fix(agent-status): keep a paired host's child-held Pi row working whe…