Repository navigation
PASS_WITH_CONDITIONS
Inputs. This rules on 71b09cf6 (arch 327e1b57). The ledger already has a CONDITIONS ruling on this same head, but its why is cut off before its conditions. No since.diff, since-conditions.json or findings.json is staged. So I read pr.diff whole and ruled on the full change again, as the ruling on #3546 at 452c7ce1 did. The checkout has no arch-map.md, so I found the sections by search.
Governs. architecture.md line 492 (min box attach: 254 when the daemon ends the attach from the other side, after a one-line notice on stderr). Line 376 (exit codes: 254 for a stop, a removal or a PTY takeover). Line 471 (min box restart: stop, then start under the same record). The spec line is the BCLI-068 254 sub-bullet in docs/specs/28-spec-box-cli: one stderr line that names the cause.
Ruling. The change is in the right owner: the min client's attach in crates/minimal/src/cmd/boxes/attach.rs (rule 8). A restart still exits 254 with one stderr line. The line now names the restart, where before it gave the takeover line, which was false. It fails closed (rule 7): when the count of ends before or after is unread, BoxRestart::Unread gives the host line and guesses no cause. attach_ending keeps every other code and state, as the unit test pins. The two fix commits after b7b93c11 are at this head: a2f89ebc (no cause on an unread count) and 71b09cf6 (a test through the host). The read window that prints 'was stopped' for a restart is true under line 492, because a restart is a stop. It is filed as gominimal/inbox#1277 (rule 6). The one open item is the live proof leg. The PR says no live restart ran, so the leg is not_run and stays open (rule 4). C1 puts that leg in T56 (#3525). The change can merge with C1 open.
Departure. The earlier CONDITIONS on this head is not readable past its first lines, so I cannot say which condition it set. I found no design line that this head breaks. Lines 376, 471 and 492 decide BCLI-068 as conforms. If the earlier ruling set a condition that I do not carry here, the next reviewer must check it against those lines.
Not checked. min task run agent-verify exited 100. otel_cli::exec_run_attach_and_task_run_share_the_commands_trace failed. Every attach to a running box now reads the count of ends before it attaches, which adds one host read in the cmd span. The test matches the daemon attach span by name and parent, so an extra read does not obviously break it. The same test had a timing flake that #3401 fixed. Whether this change causes the failure needs a test run, which this review does not do. It is a test fact for minimal-review, not a design deviation. The draft state stays until verify is green. I could not open gominimal/inbox#1277 or #3525 (no gh in the sandbox). The URLs are as the PR body gives them.
Conditions
- C1: The live proof leg of this task is not run: no real
min box restartended a real attach. Under T56 (#3525), add a step toscripts/session-e2e.shthat attaches to a runninguntil_stoppedPTY box, runsmin box restart <box>from a second client, and asserts exit 254 and the one restarted line on stderr. Until that step runs green, the leg stays open.
Ruled at 71b09cf against gominimal/arch@327e1b57d16b by claude-opus-5-5; arch_rulings 1386, job 7be62e20-dc8d-4c6a-be5d-1feb7a7e8c52.