Repository navigation
Description
Summary
On macOS, a local supervised worker-start can create the agent terminal but fail before delivering the injected lifecycle preamble. The Dispatch then fails at dispatch_input with agent_prompt_stalled, its capability is revoked before worker_done, and subsequent worker-release can remain release_unknown with tab_not_found.
This was reproduced twice in Orca 1.4.188: once before and once after a complete manual app relaunch (new runtime epoch). The in-app updater reported that this was the latest version.
Reproduction
- Use a local, existing non-main worktree.
- From a local coordinator, create a Run and a ready Task.
- Start a fresh Codex worker with the public lifecycle path:
orca orchestration worker-start --task <task-id> --worktree <existing-worktree> --agent codex --json- Inspect the Dispatch and then release the exact settled worker:
orca orchestration dispatch-show --task <task-id> --json
orca orchestration worker-release --dispatch <dispatch-id> --jsonActual result
worker-startreturns a structured receipt withstate: failed,stage: dispatch_input, andlastError: agent_prompt_stalled.- The agent terminal is listed as a residual resource, but the Dispatch has
capability_revoked_atand fails before any worker heartbeat orworker_done. - On the second reproduction after relaunch,
worker-releasereturnedstate: release_unknown,lastError: tab_not_found. The documented idempotent retry returned the same result. worker-showthen reported the exact worker terminal as disconnected and non-writable, withexitCause: operator_close; no manual terminal input or broad terminal close was issued by the reproducer.
Expected result
A fresh local worker-start should deliver a valid lifecycle capability and preamble, allowing the worker to report worker_done. If startup fails after terminal creation, the exact worker-release path should settle the owned terminal without tab_not_found or release_unknown.
Scope / related reports
This is a local macOS reproduction, not a federated/WSL case. It may be related to persisted-tab desynchronization, but it is not the same entry point as:
- CLI
terminal closecan never close a background tab that failed reveal — headless close path throwstab_not_foundfor tabs that were never persisted #10747 (failed-reveal background terminal close) - Closing a terminal tab with a missing persisted session record resurrects the tab — close aborts on tab_not_found before PTY kill and snapshot prune #12920 (UI resurrection after
tab_not_found)
The failure here originates at lifecycle dispatch input during worker-start, before a valid worker lifecycle can begin.
Safety
The reproduction used only documented orchestration commands. It did not edit repository files, delete worktrees/branches, restart the runtime programmatically, or inject terminal input to bypass lifecycle.
Activity
rossinsilico commentedon Aug 22, 2026
Adding another macOS reproduction from a multi-agent Codex run. This closely matches the lifecycle failure reported here, with one potentially important variation: the workers appeared to be actively running even though Orca classified prompt submission as stalled.
Observed sequence:
agent_prompt_stalledafter roughly 15 seconds.worker_done.tab_not_found, leaving lifecycle cleanup uncertain even though the terminal transcript had been captured.We found no corresponding repository or task failure. The failure was in Orca’s orchestration-control state: the terminal and agent were alive and making progress while the Dispatch had already been failed and fenced.
This suggests that at least some
agent_prompt_stalledcases may be false negatives in turn-start verification, rather than the prompt actually failing to reach or start the agent.A useful recovery path would be a safe way to reattach or re-mint lifecycle authority for a terminal that is demonstrably active after a false
agent_prompt_stalled, without closing the terminal or discarding its in-context work.We can provide sanitized JSON receipts, timestamps, runtime IDs, terminal/Dispatch IDs, and transcript excerpts if they would help isolate the verification or cleanup path.
kevinblade commentedon Aug 26, 2026
Adding a contrasting macOS 1.4.188 reproduction that isolates the release path from the
agent_prompt_stalledstartup failure.Environment:
1.4.18867968bfe-cdb5-41a1-93b3-7ac286b773470.149.1Sequence:
worker-startsucceeded for a fresh local Codex worker (task_2588f418bb11, Dispatchctx_0814554f742e, terminalterm_572a7d03-adc8-455f-8dfc-427d63cfaddc).worker_done(msg_136f10760f61). There was no startup stall or failed lifecycle capability.worker-showproved the exact owned terminal was live,connected: true,writable: true,exactWorker: true, with tabbb2043ff-68ae-4a97-a027-593edfb7646dand leafbe401e22-d748-4b52-a74a-cf833ad50adc. The resource release state wasnot_requested.worker-release --dispatch ctx_0814554f742ecaptured the transcript but returnedstate: release_unknown,lastError: tab_not_found,processAction: none.worker-showwas repeated andworker-releasewas replayed with the original retry request6b748a16-c131-482c-b32c-745d0cb2f4f5. The mutation was recognized as replayed/idempotent and returned the same result. No broadterminal closewas substituted.operator_close, but the owned terminal resource still hadreleaseState: unknown,releaseCompletedAt: null, andreleaseError: tab_not_found.Expected: after an accepted
worker_done, releasing the exact owned terminal should durably settle as a known disposition.This suggests
tab_not_found/unknown settlement is not limited to thedispatch_inputfailure described in the issue body: it also occurs after a fully successful lifecycle, even when the exact tab/leaf is resolvable immediately before release.The in-app updater was checked again on 2026-08-26 and reported
1.4.188as the latest version. Full sanitized evidence is recorded here: https://github.com/kevinblade/convexa/blob/main/docs/releases/development-gate1-settlement-reproduction-2026-08-26.mdhierosir1984 commentedon Aug 26, 2026
Linux confirmation of the release path on Orca 1.4.188, independent of startup failure.
A supervised Codex worker reached input_accepted, sent an accepted typed worker_done, and completed normally. The exact worker terminal was coordinator-owned. worker-release captured its attested transcript, closed the terminal, then returned release_unknown with tab_not_found. The required same-request retry returned the same result. worker-show afterwards reported the terminal exited with operator_close while the resource remained releaseState unknown.
The worker-start receipt contained the warning that the background terminal was running but Orca could not make it discoverable. The packaged closeTerminal implementation still followed the pty.tabId plus notifier.closeTerminalTab branch. It awaits the UI tab close before calling stopExplicitlyClosedTabPtys. When the undiscoverable background tab produces tab_not_found, completeWorkerTerminalRelease catches that exception and records release_unknown even though the terminal has already disappeared.
The smallest safe correction is to treat tab_not_found from the UI close as an absent UI surface, then continue the exact owned PTY stop and liveness verification. Settlement should become released only when the addressed PTY is proven stopped or already exited. This preserves the existing fail-closed rule without leaving successful workers permanently counted as release_unknown.
kevinblade commentedon Aug 27, 2026
Retested the successful-lifecycle release case after updating to Orca
1.4.190; the issue still reproduces on a new runtime epoch.Environment:
1.4.190775575d0-fb81-474a-85e7-2c514cdf17140.149.1, Apps stable/enabledtrueFresh comparison run:
run_7ea615f21867task_294f7517b483ctx_da4870d3c492term_b28195d7-a2ee-439f-8d7a-d7a2872fdeddThe worker again completed the normal path:
input_accepted, heartbeatmsg_9e5f48a9bce4, accepted typedworker_donemsg_ec826a7e6b0e, Dispatch completed/succeeded. Immediately before release,worker-showreported the exact owned terminal live, connected and writable, with tab6009e2f1-2632-4a82-94b7-62fd92561a3a, leaf94895a14-42ac-48b7-92ea-22f9e3314531,exactWorker: true, andreleaseState: not_requested.The first exact
worker-releasecaptured the transcript but returned:Following the receipt exactly, I inspected the same Dispatch and replayed release with mutation request
c64ec234-3a5b-4bee-a920-7b339530c788. Orca recognized it as an idempotent replay and returned the same result. The post-release worker observation was exact/exited withoperator_close, but the owned resource still hadreleaseState: unknown,releaseCompletedAt: null, andreleaseError: tab_not_found. No broad terminal close was substituted.This is the same contrasting path as my previous comment: no
agent_prompt_stalledand no lifecycle failure before settlement. The app version and runtime epoch both changed from the 1.4.188 reproduction, but exact owned-terminal release remains unknown.wonjo-linc commentedon Aug 30, 2026
Adding a Windows-hosted local WSL reproduction on Orca
1.4.192. This is the successful-lifecycle release path, not anagent_prompt_stalledresult.Environment:
1.4.1920.151.0AGENTS.md, setup script, or product filesSequence:
state=ready,stage=input_accepted, andhookFound=false.worker_donewithoutcome=succeeded; the Task and Dispatch settled as completed/succeeded. The coordinator immediately verified the message identity, archived output, and clean unchanged Git HEAD.worker-showreported the exact coordinator-owned terminal live withexactWorker=true,ownershipState=owned, andreleaseState=not_requested.worker-releasecaptured the archive and closed the agent terminal, but returned:worker-showreported the same exact process incarnation asstatus=exited,exactWorker=true, terminal disconnected/non-writable,exitCause=stop_unverified, andpaneRuntimeId=-1. The terminal resource still remainedownershipState=owned,releaseState=unknown, with noreleaseCompletedAt.worker-releasewith the original retry request was recognized asreplayed=trueand returned the samerelease_unknownresult.project setup-delete, and the clean disposable root was moved to trash. None of those observations were treated as a substitute for rawreleasedsettlement.This confirms that the successful worker lifecycle release problem still reproduces on
1.4.192in local WSL. The observable variant differs from the earliertab_not_found/processAction=nonereports: here Orca reportsprocessAction=closed_agent_terminal, the exact process is subsequently observedexited, but the resource ledger remainsrelease_unknownbecause the stop verdict is unverified.Sanitized local identifiers, paths, runtime IDs, and Dispatch capability material are intentionally omitted. I can provide additional sanitized receipt fields if useful.
wonjo-linc commentedon Aug 30, 2026
One additional bounded comparison on the same Orca
1.4.192local WSL profile: I tested the documentedworker-stopbeforeworker-releaseas a materially different settlement sequence.A fresh hookless supervised Codex worker again reached
input_accepted, sent an acceptedworker_done, and settled completed/succeeded with a clean unchanged fixture. After the coordinator graded the result,worker-stop --dispatch <completed-dispatch>returned:The exact owned terminal remained live. The following exact
worker-releaseagain returnedrelease_unknownwithprocessAction=closed_agent_terminal; follow-up observation was exact/exited and the resource ledger remained owned/unknown.So
worker-stopis not currently a workaround onceworker_donehas already settled the Dispatch. It treats the logical Dispatch as already settled and does not establish a process stop verdict for the still-owned terminal before release.tbeugin-ext commentedon Sep 1, 2026
Linux confirmation on the latest published desktop release, Orca
1.4.194. This is the successful-lifecycle path, not anagent_prompt_stalledstartup failure.Environment:
serve), normal user1.4.1940.152.0Observed sequence:
worker-startreachedstate=ready/stage=input_accepted.worker_done; its Task and Dispatch settled as completed/succeeded.worker-release --dispatch <dispatch> --retry-request <stable-request>captured the transcript and removed the visible worker surface, but returned:mutation.replayed=true) and returned the samerelease_unknownresult.ownershipState=owned,releaseState=unknown,releaseError=tab_not_found, although the worker itself was settled and its visible tab was no longer available.Impact in a durable FIFO consumer: the oldest Delivery cannot be acknowledged safely because release never reaches a documented terminal disposition. A later independent
worker_donein the next Delivery is therefore blocked behind it. We deliberately did not substitute a broad terminal close or fabricate an acknowledgement.Expected: exact owned-worker release should converge to
released(or a documentedretaineddisposition) once the addressed PTY is proven stopped or absent, and an exact replay should expose that terminal accounting.I also checked the published release history before reporting this:
1.4.194is currently the newest desktop release, and neither its notes nor1.4.193include this fix. Open PR #16515 explicitly describes a headless cleanup correction for the sameworker_done -> worker-release -> release_unknown -> tab_not_foundpath, but it is not merged or released yet.wrightbuilt commentedon Sep 2, 2026
macOS confirmation on Orca
1.4.194, successful-lifecycle path, plus two behaviors I have not seen in this thread yet: what a retried release does to the ledger, and whatworker-abandonsays.Environment: macOS (Darwin 25.6.0), local runtime, Orca desktop
1.4.194, supervised Codex and Claude workers started with the public lifecycle (worker-start, accepted typedworker_done).Scale.
worker-list --jsonon this workstation before cleanup:{ "release_unknown": 35, "released": 17, "retained": 8, "active": 4 }. All 35 unknown rows share the shape already described here:workerState=succeeded,dispatchStatus=completed,archive.status=captured,releaseError=tab_not_found, terminal handle absent fromterminal list. They accumulated across four coordinators over about ten days.Retrying release changes the row, but not to
released. A second exactworker-releaseon arelease_unknown/tab_not_foundrow returns:{ "state": "retained", "reason": "identity_unproven", "processAction": "none", "archive": { "source": "transcript", "status": "captured" } }and
worker-listthen showsreleaseState=retained,retainedReason=identity_unproven. Reproduced on 18 of 18 rows. So the retry is not a no-op: it silently converts an unknown release into something indistinguishable from a deliberateworker-retain, which makes the ledger harder to audit, not easier.worker-abandonrefuses a settled dispatch.Combined with the above, a coordinator has no command that settles a completed dispatch whose tab is already gone, and no command to close a Run whose coordinator terminal is gone.
#13860described the same dead end forexternal_terminal; on1.4.194a release of a dispatch whose terminal was launched byworktree create --agentstill returnsretained / external_terminal.Expected, same as above: once the addressed PTY is proven absent, exact release should converge to
released(or a documented terminal disposition), and a replay should be a no-op rather than a state change. Happy to supply sanitized receipts.haden111 commentedon Sep 4, 2026
Independent confirmation of the failed-start / cleanup problem from our Windows development workflow.
We had
worker-startfailures arounddispatch_input/ prompt delivery where the attempted worker had already created Orca resources. Recovery then became another failure mode rather than a reliable cleanup operation.In particular, we encountered the same family of outcomes described here:
release_unknown/ missing-tab-style outcomes are especially problematic for unattended orchestration because the coordinator cannot safely answer either:We eventually stopped using Orca as the primary development orchestrator because failures like this required human inspection and recovery of terminals/worktrees.
I have not yet rerun this exact reproduction on 1.4.196, so this is independent historical impact evidence rather than a claim that every detail still reproduces on the latest tag.
The contract we need is simple: if
worker-startpartially creates resources and then fails, an idempotent release of the exact Dispatch must eventually produce a definite terminal result: released, already released, or an actionable error explaining what still owns the resource.release_unknownis not sufficient for unattended recovery.