Skip to content

test(minimald): T29 — One digest both sides, end to end - #3460

Open
minimal-foundry[bot] wants to merge 1 commit into
mainfrom
agent/2434-one-digest-both-sides-end-to-end
Open

minimal-foundry[bot] wants to merge 1 commit into
mainfrom
agent/2434-one-digest-both-sides-end-to-end

Conversation

@minimal-foundry

Copy link
Copy Markdown
Contributor

T29 — One digest both sides, end to end

slice: S6
kind: integration
covers: none
size: S
est: 40 code, 120 tests
executor: agent
difficulty: routine
model: light
diagnostics: daemon log names both digests
observability: one span covers digest path
layers:
- slice:
- crates/minimald/src/box_manager/tests.rs: tests
test: cargo nextest run -p minimald client_and_daemon_digests_match_vectors_and_mismatch_refused
produces: none
consumes: none
proof: create a box and see the client's and the daemon's projection digests stored side by side, equal to the golden vectors, and a mismatch refused.
depends on:
- blocked by #2430
- blocked by #2431
- blocked by #2432
- blocked by #3387

Proof

A person can run the test and see this. For each expanded spec in crates/mfile/tests/golden/vectors.json (example/dev, example/render-diagrams, defaults_session_only/default), the client's projection digest and the daemon's recomputed digest are stored side by side in the created box's record. Both equal the pinned golden digest. A create whose client digest is another vector's digest is refused with the projection digest mismatch error and leaves no record. The daemon log names both digests.

Notes from the agent: The test reads the golden vectors from crates/mfile/tests/golden/vectors.json and uses no new fixture. The client side copies the projection path in crates/minimal/src/cmd/boxes/create.rs (stamp_client_projection_digest): it parses a TOML table and runs TypeFacts::of_spec, then project().digest(). minimald has no toml dependency, and Cargo.toml is outside the layers. So the test parses the table with str::parse, and of_spec fixes its type by inference. The test cannot call the minimal crate's function directly, because minimald does not depend on that crate. Finding: the golden expanded specs carry no v, and the daemon refuses a spec without one ('box spec without a version'). The test adds v = BOX_SPEC_VERSION to the JSON that it sends, as the typed BoxSpec that min sends today does. The daemon's digest still equals the vector, which shows that v is outside the projection. A later task that sends the expanded spec in place of the typed one (#2410) must add v to the expansion. Otherwise the daemon refuses every create. The verb type for each vector comes from the projection's type.root, so the session vectors are created under the session verb and the task vector under the task verb. diagnostics and observability: the existing create span and log line already name both digests. The test asserts the log line on each refusal. I did not run the whole crate's suite or just ci.

Tests

line exit tail
cargo nextest run -p minimald client_and_daemon_digests_match_vectors_and_mismatch_refused 0 warning: unknown fields in task runtime-implement-test-0: network help: do you need to update to a newer version of minimal? Running task runtime-implement-test-0 in box runtime-implement-test-0-1... Compiling paths v0.0.1 (/workbench/crates/paths) Compiling args v0.0.1 (/workbench/crates/args

Verify

min task run agent-verify timed out after 1800s, so this PR is a draft.

HE_REGION=auto\u{1f}SCCACHE_S3_USE_SSL=true\u{1f}SHELL=/usr/bin/bash\u{1f}SHLVL=2\u{1f}SSL_CERT_DIR=/etc/ssl/certs\u{1f}SSL_CERT_FILE=/etc/ssl/cert.pem\u{1f}XDG_CACHE_HOME=/state/cache\u{1f}XDG_CONFIG_HOME=/home/.config\u{1f}XDG_DATA_HOME=/home/.local/share\u{1f}XDG_RUNTIME_DIR=/run\u{1f}XDG_STATE_HOME=/home/.local/state\u{1e}stdin\n"
    note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

  Cancelling due to test failure: 3 tests still running
        PASS [   0.796s] ( 609/1503) minimald env::tests::refresh_does_not_adopt_the_repos_top_levels
        PASS [   0.777s] ( 610/1503) minimald env::tests::refresh_remaps_the_installed_set_onto_the_new_graph
        SLOW [> 60.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>120.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>180.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>240.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>300.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>360.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>420.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>480.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>540.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>600.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>660.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>720.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>780.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>840.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>900.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>960.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1020.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1080.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1140.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1200.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1260.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1320.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1380.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task
        SLOW [>1440.000s] (─────────) minimald env::tests::minenv_run_forwards_stdin_to_the_task

Closes #2434

Each expanded spec in crates/mfile/tests/golden/vectors.json goes
through the client's projection and a daemon create. The record stores
both digests, equal to the vector's, and a create that carries another
vector's digest is refused with no record left behind.
@coderabbitai

coderabbitai Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 0dca8e02-5b28-4885-89ca-3fbf0a16b7ea

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@minimal-foundry

minimal-foundry Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor Author

Approved: no findings at 85ffbf19f3c7.

Nothing to do.

Verdict APPROVE, posted as a comment: the App cannot review its own pull request; the check and the label carry it.

Clobber: none, the diff is additive.

@minimal-arch minimal-arch Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

arch-review: PASS · the full ruling

The change adds one test and no production code. The test proves Gatehouse §6.3 check 5 and architecture.md line 1291 over the golden vectors. The client and the daemon compute the same digest, the record stores both, and a differing digest is refused with no record. The test asserts the existing gate and does not relax it. The full verify run timed out in an unrelated module, so CI must still pass before merge.

Ruled at 85ffbf1 against gominimal/arch@327e1b57d16b by claude-opus-5-5.

@minimal-foundry minimal-foundry Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minimal-review — approved

Verdict APPROVE — No findings.

Panel: 3 of 3 personas ran (correctness, security, supply-chain).

@minimal-foundry minimal-foundry Bot added the review:approved minimal-review approved the current head label Nov 16, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

review:approved minimal-review approved the current head

Projects

None yet

Development

Successfully merging this pull request may close these issues.

T29 — One digest both sides, end to end

0 participants