Repository navigation
Commit 7511e77
committed
✨ Route a pane's native launch through its own composite (#732)
Implements architecture commit 802b07d.
`TerminalComposite.launch(ordinal, request, spawned)` is required of every
composite. Core closes the pane-scoped launcher over it and the pane's authored
ordinal, so after claim admission and the pane flush a `<Session.Launch>`
written in a paired pane reaches *that pane's* terminal. The ordinal lives in
core's closure and enters no native request, Agent request, session key,
construction route, durable phase, result or diagnostic.
The pane launcher is now the end of the chain. Middleware written nearer the
authored launch still composes in front and may observe, wrap, refuse or
short-circuit; what it can no longer do is reach past, because past it is the
root foreground launcher and the root terminal is the one thing a pane exists
to avoid. A composite that cannot run a pane's launch refuses — there is no
fallback, because the only thing to fall back to is the wrong terminal. Root
`<Session.Launch>` is untouched.
The tmux composite sends the exact command vector, working directory and
environment over the pane's authenticated channel; tmux's parser sees a
directory and an ordinal. `shell()` stays separate and keeps deriving the
executable from live host policy. `spawned` is invoked only for the
worker-observed runtime spawn event.
Also fails closed on settlement: `requireQuiescent()` is the rule everything
downstream is conditional on, and a settlement that could not prove the pane
free no longer clears the pane, reports success, or admits another launch.
TG20 proves the endpoint against real workers on real sockets with a fake tmux
that now starts the pane commands it is given, and with no `<TestAgent>` or
nearer launcher in front: exact argv, cwd and environment arrive at the pane's
authenticated worker; a root-foreground-launcher sentinel is never entered while
a root launch still reaches it; distinct panes launch concurrently; and a pane
the composite cannot serve refuses.
Tier GN is rewired through the endpoint, which is what exposed the gap: before
this, its pane launches reached `<TestAgent>`'s launcher and nothing could tell
that from reaching the pane. GN now separates the two — `launches` at the pane
endpoint, `agentLaunches` at the root route — and GN3 and GN8 assert both.1 parent 802b07d commit 7511e77
10 files changed
Lines changed: 544 additions & 73 deletions
File tree
- packages
- cli
- src/terminal
- tests
- fixtures
- core
- src
- terminal
- tests
- runtime
- test-agent/tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
92 | 128 | | |
93 | 129 | | |
94 | 130 | | |
| |||
176 | 212 | | |
177 | 213 | | |
178 | 214 | | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
179 | 218 | | |
180 | 219 | | |
181 | 220 | | |
| |||
231 | 270 | | |
232 | 271 | | |
233 | 272 | | |
234 | | - | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
235 | 276 | | |
236 | 277 | | |
237 | 278 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
| 29 | + | |
28 | 30 | | |
29 | 31 | | |
30 | 32 | | |
| |||
175 | 177 | | |
176 | 178 | | |
177 | 179 | | |
178 | | - | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
179 | 193 | | |
180 | 194 | | |
181 | 195 | | |
| |||
201 | 215 | | |
202 | 216 | | |
203 | 217 | | |
204 | | - | |
205 | | - | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
206 | 227 | | |
207 | | - | |
| 228 | + | |
208 | 229 | | |
209 | | - | |
| 230 | + | |
210 | 231 | | |
211 | | - | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
212 | 235 | | |
213 | | - | |
214 | 236 | | |
215 | 237 | | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
220 | 242 | | |
221 | 243 | | |
222 | 244 | | |
223 | 245 | | |
224 | | - | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
225 | 249 | | |
226 | 250 | | |
227 | | - | |
228 | | - | |
| 251 | + | |
| 252 | + | |
229 | 253 | | |
230 | 254 | | |
231 | 255 | | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
232 | 259 | | |
233 | | - | |
| 260 | + | |
234 | 261 | | |
235 | 262 | | |
236 | | - | |
| 263 | + | |
237 | 264 | | |
238 | 265 | | |
239 | 266 | | |
| |||
245 | 272 | | |
246 | 273 | | |
247 | 274 | | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
248 | 278 | | |
249 | 279 | | |
250 | 280 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
| |||
56 | 58 | | |
57 | 59 | | |
58 | 60 | | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
59 | 70 | | |
60 | 71 | | |
61 | 72 | | |
| |||
66 | 77 | | |
67 | 78 | | |
68 | 79 | | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
69 | 84 | | |
70 | 85 | | |
71 | 86 | | |
| |||
97 | 112 | | |
98 | 113 | | |
99 | 114 | | |
| 115 | + | |
100 | 116 | | |
101 | 117 | | |
102 | 118 | | |
| |||
127 | 143 | | |
128 | 144 | | |
129 | 145 | | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
130 | 160 | | |
131 | 161 | | |
132 | 162 | | |
| |||
274 | 304 | | |
275 | 305 | | |
276 | 306 | | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
277 | 313 | | |
278 | 314 | | |
279 | 315 | | |
| |||
0 commit comments