8000 test(minimal): box addresses and -o json output, end to end · gominimal/minimal@9a9a3e0 · GitHub
[go: up one dir, main page]

Skip to content

test(minimal): box addresses and -o json output, end to end

Minimal Arch / arch-review completed Nov 4, 2026 in 0s

PASS_WITH_CONDITIONS

Governs: architecture.md Addressing line 389 (id, name, or provider/host/name). Exit codes line 365 (4, not found) and line 368 (7, provider/host unreachable). Output conventions line 381 (every -o json object carries min/v1/<type>), line 383 (the machine-mode error object, shown with code not_found) and line 384 (secrets never appear in any output mode). Design principle 4 (line 334). Agent Use Cases line 249 lists min box show <box|self> -o json.

Ruling: The change is test-only, in crates/minimal/src/tests.rs, the one layer that T6 names (rule 8). The test conforms to lines 365, 368, 381, 384 and 389 for what the product does today. The change to box_command_ending matches failure_exit_code in main.rs line 261 (BoxAddressRefusal::exit_code), so the T3 test keeps its meaning. The PR body lists three product gaps against the proof, and I confirmed each one in the source. (1) No command renders a Secret, so the line-384 check goes through a test-only Rendered object. (2) cmd_box_show in show.rs has no -o json, against line 249. (3) machine_mode_answer in main.rs has no BoxAddressRefusal branch, so exit 4 and exit 7 write code unspecified, which is exit 1's label, against line 383. Gap (3) came with T4 (#2987), not with this change. All three are outside this task's layer, so they are residuals and not deviations of this change. The body says "a later task can add" them and names no issue. Rule 6 refuses a residual with no issue, so C1, C2 and C3 file them. The change can merge with them open once they are filed.

Precedent: This ruling follows #2987 (T4) on the addressing and exit-code lines, and #2984 (T3) on the harness pattern. It departs from neither.

Not checked: I did not check that the test passes. A build is out of bounds, and the PR's own run shows it green. The verify run failed on otel_cli::exec_run_attach_and_task_run_share_the_commands_trace under an unpinned rustc 1.99.0. This change does not touch that test, and I did not investigate it. I could not search the issue tracker because gh is not in the sandbox, so I do not know whether issues for the three gaps already exist. If they exist, link them to meet C1 to C3. The test's show closure copies cmd_box_show because that function writes to process stdout. Its UNKNOWN_SESSION_ID_LEAD branch (a box removed after resolution) is therefore not exercised. That is a test-scope note for minimal-review and not a design deviation.

Conditions

  • C1: File an issue in gominimal/minimal for gap (3): crates/minimal/src/main.rs machine_mode_answer() gets a minimal::BoxAddressRefusal branch. That branch writes code not_found for NotFound (exit 4) and host_unreachable for Unreachable (exit 7), not unspecified. Link the issue URL under a ## Residuals heading in the PR #3006 body, in place of "A later task can add not_found and host_unreachable codes there".
  • C2: File an issue in gominimal/minimal for gap (2): min box show <box|self> -o json writes one min/v1/box object, and the T6 end-to-end test reads it. Link the issue URL under the ## Residuals heading in the PR #3006 body.
  • C3: File an issue in gominimal/minimal for gap (1): the first command that renders a Secret writes it through output::write_object, and the secret check in box_address_and_json_output_end_to_end moves from the test-only BoxSecret object to that command. Link the issue URL under the ## Residuals heading in the PR #3006 body.

Ruled at 9a9a3e0 against gominimal/arch@7a86ec7bb3c0 by claude-opus-5-5; arch_rulings 902, job 4eda7d81-842e-4737-83b1-9cc488f0af01.

0