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
Not a measured defect at filing time; updated on 2026-09-13 to what the tree does after #1163 landed, so the open question is stated against the current code rather than the original one.
What is true today
spawn writes no placement record for a plain member. The tmux and herdr branches of spawn.sh call _record_placement <terminal> <id> after launching; the plain branch launches the window, requires the driver to return -, and returns without recording anything. So run/spawn.<team>__<agent> does not exist for a plain member, and despawn --force, peek and poke — which all begin by reading that file — answer "no placement record" before any driver is asked.
The driver can now address a plain seat, when someone knows where it is.#1163 gave the plain driver emulator-qualified references, plain:iterm:/dev/ttysNNN and plain:terminal:/dev/ttysNNN, with a measured adapter per emulator and a runtime capability hook (terminal_capability) that can only narrow the static manifest: spawn is supported; peek and poke are supported once a reference parses and the adapter probe finds that tty in that emulator; despawn answers unsupported: plain window teardown needs an owner process witness. ITERM_SESSION_ID and TERM_SESSION_ID are deliberately not used, because live seats on distinct ttys were measured inheriting the same launcher value.
What no one knows at launch is the tty.terminal_spawn on plain opens the window through open -g -a …, a {cmd} template, or a Linux/Windows emulator, none of which return a handle; it prints - because that is all it has. terminal_detect prints - for the same reason. The seat itself is the first thing that can know its tty (its own controlling terminal), which is why the reference grammar exists without a producer for it in spawn.
Teardown is unchanged.terminal_despawn still prints ok and returns 0, and terminal_pane_state still returns 13 with "unknown", on the same reasoning as before: an OS window holds no pid the driver can kill, and a spurious error would be worse than "nothing to tear down". The capability hook's despawn → unsupported is the honest statement of the same fact one layer up.
The question, restated
The original question stands and is still unmeasured: after despawn on a plain member, is the window still on screen? If the boot command exits with the seat and the window closes itself, "ok, nothing to tear down" is exactly right. If the window survives, nothing can reach it afterwards — and after #1163 that is no longer because the driver cannot address a plain seat, but because no record names it: the address (plain:<emulator>:<tty>) is only known to the seat.
Once such a record exists, peek/poke work through feat(terminal): address measured plain emulators #1163's adapters, and despawn --force has a reference to hand the driver — which is where "needs an owner process witness" becomes a concrete thing the record can carry.
How to settle it
Unchanged: spawn a plain member, despawn it, look at the screen. It opens a real window on someone's desktop, so it is a thing to do with permission, not in passing. Until then this issue records two facts, not one: no record is written at launch, and the driver would now know what to do with one.
Not a measured defect at filing time; updated on 2026-09-13 to what the tree does after #1163 landed, so the open question is stated against the current code rather than the original one.
What is true today
spawnwrites no placement record for a plain member. The tmux and herdr branches ofspawn.shcall_record_placement <terminal> <id>after launching; the plain branch launches the window, requires the driver to return-, and returns without recording anything. Sorun/spawn.<team>__<agent>does not exist for a plain member, anddespawn --force,peekandpoke— which all begin by reading that file — answer "no placement record" before any driver is asked.The driver can now address a plain seat, when someone knows where it is. #1163 gave the plain driver emulator-qualified references,
plain:iterm:/dev/ttysNNNandplain:terminal:/dev/ttysNNN, with a measured adapter per emulator and a runtime capability hook (terminal_capability) that can only narrow the static manifest:spawnis supported;peekandpokeare supported once a reference parses and the adapter probe finds that tty in that emulator;despawnanswersunsupported: plain window teardown needs an owner process witness.ITERM_SESSION_IDandTERM_SESSION_IDare deliberately not used, because live seats on distinct ttys were measured inheriting the same launcher value.What no one knows at launch is the tty.
terminal_spawnon plain opens the window throughopen -g -a …, a{cmd}template, or a Linux/Windows emulator, none of which return a handle; it prints-because that is all it has.terminal_detectprints-for the same reason. The seat itself is the first thing that can know its tty (its own controlling terminal), which is why the reference grammar exists without a producer for it inspawn.Teardown is unchanged.
terminal_despawnstill printsokand returns 0, andterminal_pane_statestill returns 13 with "unknown", on the same reasoning as before: an OS window holds no pid the driver can kill, and a spurious error would be worse than "nothing to tear down". The capability hook'sdespawn → unsupportedis the honest statement of the same fact one layer up.The question, restated
The original question stands and is still unmeasured: after
despawnon a plain member, is the window still on screen? If the boot command exits with the seat and the window closes itself, "ok, nothing to tear down" is exactly right. If the window survives, nothing can reach it afterwards — and after #1163 that is no longer because the driver cannot address a plain seat, but because no record names it: the address (plain:<emulator>:<tty>) is only known to the seat.Where this connects
plain:<emulator>:<tty>record, and self-write: the seat's own identity writer, its fence, and a seat-local lock (#1152) #1157 implements it: the plain driver's fence observes the seat's tty through the seat's own CLI process (ps -o tty=on its pid, never the environment), refuses by name when the process has no controlling tty or sits on a different tty than the locator names, carries the owning pid and its start time as the anchor (so a recycled/dev/ttysNNNcannot pass as an old match), and treats the emulator half as delivered, not as evidence. On any of those refusals the seat writes nothing. Label, key and session are reported as unsupported in the driver's own words (feat(terminal): address measured plain emulators #1163: no adapter in this implementation, not "the emulator cannot").peek/pokework through feat(terminal): address measured plain emulators #1163's adapters, anddespawn --forcehas a reference to hand the driver — which is where "needs an owner process witness" becomes a concrete thing the record can carry.How to settle it
Unchanged: spawn a plain member, despawn it, look at the screen. It opens a real window on someone's desktop, so it is a thing to do with permission, not in passing. Until then this issue records two facts, not one: no record is written at launch, and the driver would now know what to do with one.