You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Paired client keeps a mirrored terminal tab for days after the host closed it (blank pane, "Remote terminal was closed.") #21236
One macOS client paired to a remote Orca server still shows a terminal tab that the host closed six days earlier. The pane is blank and shows Remote terminal was closed. The host and the two other macOS clients paired to the same host no longer have the tab.
Evidence (UTC)
09-11 07:09:40, host trace:terminal.close for the tab, sent from this same client's device, outcome: "succeeded", ptyKilled: true.
09-11 09:46:06, host trace:terminal.closeTab for the same tab (origin: "in-process", closeMode: "tab"), outcome: "succeeded".
09-17, host and other clients: the host's orca-data.json has no tab with that id; neither do the persisted states of the two other paired clients.
09-17, this client: its orca-data.json still holds the tab under workspaceSessionsByHostId["runtime:<id>"]:
a tabsByWorktree entry web-terminal-<id> with ptyId: null
a terminalLayoutsByTabId entry with a single leaf and ptyIdsByLeafId: {}
a matching unifiedTabs entry
a leftover sleepingAgentSessionsByPaneKey record for the pane (state: "done")
shouldReplaceTerminalTab (src/renderer/src/runtime/web-session-tabs-sync/terminal-surfaces.ts) returns true for every mirrored surface id. A host snapshot that reconciles terminal tabs for this workspace should therefore drop the tab, and the same check exists in 1.4.205. The tab survived anyway, so it is kept by some other path. I could not tell which: either no reconciling snapshot for this workspace reached this client, or the tab is restored from persisted state after being dropped.
Expected behavior
Once the host has closed a mirrored tab and stopped publishing it, paired clients drop it instead of keeping a dead pane for days.
Cross-referencing: Linking PR #21277 and PR #20922 as part of the broader remote tab lifecycle hardening. While #21236 tracks mirrored paired terminal tabs lingering after host closure, PR #21277 ensures that when users dismiss absent or already-closed tabs, absent worktree selectors are handled idempotently on the host and close intents remain durable on the client rather than resurrecting.
Thanks for the report, @yulin0629. Fixed in #33926: after the desktop itself changed a remote workspace's tabs (for example removing a worktree), it ignored every later tab save from the window for that project. So after a restart those workspaces came back with no tabs of their own. Now that hold only lasts a few seconds, so the window's saves win again. Please reopen if you still see it on a current build.
Activity
AmethystLiang commentedon Sep 17, 2026
thanks for reporting. looking into it
LesleyMurfin commentedon Sep 17, 2026
Cross-referencing: Linking PR #21277 and PR #20922 as part of the broader remote tab lifecycle hardening. While #21236 tracks mirrored paired terminal tabs lingering after host closure, PR #21277 ensures that when users dismiss absent or already-closed tabs, absent worktree selectors are handled idempotently on the host and close intents remain durable on the client rather than resurrecting.
test(persistence): pin that a window save can drop a tab the server c…
fix(persistence): a paired server's workspaces keep their saved tabs …
nwparker commentedon Oct 26, 2026
Thanks for the report, @yulin0629. Fixed in #33926: after the desktop itself changed a remote workspace's tabs (for example removing a worktree), it ignored every later tab save from the window for that project. So after a restart those workspaces came back with no tabs of their own. Now that hold only lasts a few seconds, so the window's saves win again. Please reopen if you still see it on a current build.