@@ -36,13 +36,17 @@ not itself a cache key.
3636
3737``` bash
3838cargo rail run --all --action build --hermetic
39+ cargo rail run --all --action build --hermetic --explain
40+ cargo rail run --all --action build --hermetic --no-cache
3941cargo rail run --all --action build --hermetic --dry-run --format json
4042```
4143
42- The first command requires a reviewed ` Cargo.lock ` and executes the explicit built-in ` cargo check ` action in a fresh
43- source, target, build, Cargo-home, home, and temporary root. Before the fetch boundary, only local-package metadata runs
44- locked/offline. The explicit fetch action may use the network; full metadata and the check then run locked/offline. The
45- JSON preview names the intended boundary without executing it; preview planning is not itself a network-denial proof.
44+ On a cold run, the first command requires a reviewed ` Cargo.lock ` and executes the explicit built-in ` cargo check `
45+ action in fresh source, target, build, Cargo-home, home, and temporary roots. Before the fetch boundary, only
46+ local-package metadata runs locked/offline. The explicit fetch action may use the network; full metadata and the check
47+ then run locked/offline. An eligible local-cache hit restores before workspace context, metadata, fetch, Cargo, or
48+ rustc starts. The JSON preview names the intended boundary without executing it; preview planning is not itself a
49+ network-denial proof.
4650Actual execution currently requires ` --action build ` ; default, profile, workflow, and other action selection is
4751rejected before workspace context or hermetic state is created.
4852Feature, target, target-kind, and profile arguments remain available after ` -- ` . Workspace/package selectors,
@@ -56,7 +60,7 @@ global wrapper records workspace and external dependency compiler units. Cargo a
5660emitted outputs, and dep-info must agree exactly or the action remains uncacheable.
5761
5862Successful executions write a redaction-safe report under ` target/cargo-rail/hermetic/reports/ ` . Read ` support ` ,
59- ` enforcement ` , ` action_key ` , ` result_digest ` , ` fetch ` , ` output_manifest ` , and ` reasons ` together:
63+ ` enforcement ` , ` action_key ` , ` result_digest ` , ` fetch ` , ` output_manifest ` , ` cache ` , and ` reasons ` together:
6064
6165- ` eligible ` currently means a pure current-host Cargo check protected by the macOS filesystem/network sandbox.
6266- ` platform_limited ` means isolated roots and offline Cargo ran, but the host could not enforce the complete boundary;
@@ -69,11 +73,31 @@ Successful executions write a redaction-safe report under `target/cargo-rail/her
6973` cargo check --all-targets ` proves compilation of library, binary, test, example, and bench units; it does not execute
7074tests or benchmarks. Ordinary ` cargo rail run ` behavior is unchanged and remains the way to run unsupported classes.
7175
72- A warm ` fetch.reused = true ` means only that the exact immutable dependency inventory was reused. P6 does not contain
73- an action-result CAS and never restores compiler outputs or Cargo fingerprints. That begins in P7. Remove reports,
74- inventories, run state, and the existing diagnostic evidence with:
76+ A warm ` fetch.reused = true ` means only that the exact immutable dependency inventory was reused. It is independent of
77+ the local action/output cache. The process-free lookup currently accepts only exact text-mode
78+ ` run --all --action build --hermetic ` , with optional ` --explain ` or ` --print-cmd ` , no ` --config ` override, and no
79+ trailing Cargo arguments. For an eligible P6 key, the cache surfaces have these meanings:
80+
81+ - ` hit ` : every CAS object and exact blob byte verified, the complete output manifest was restored into a new root, and
82+ the hermetic ` cargo check ` action and compiler units did not execute;
83+ - ` miss ` : no action-key pin exists, so cold execution may populate it;
84+ - ` corrupt ` or ` incompatible ` : a selected pin or object was missing, malformed, tampered, oversized, or from another
85+ schema. The command fails with an explanation; use ` --no-cache ` for an intentional cold run or ` clean --cache ` for
86+ validated cleanup;
87+ - ` disabled ` : ` --no-cache ` was requested or the cache root/reference was unavailable;
88+ - ` uncacheable ` : P6 did not issue an eligible action key.
89+
90+ These booleans are named ` cargo_check_executed ` and ` compiler_units_executed ` deliberately. A hit launches no Cargo,
91+ rustc, or rustdoc process, but it is an action/output restore rather than native per-invocation compiler caching. The
92+ lookup digest is non-authorizing; retained P6 inputs, all CAS objects, exact blob bytes, and final platform/input state
93+ must verify. Cache objects default to ` $CARGO_HOME/cargo-rail/local-cas-v1 ` or
94+ ` $HOME/.cargo/cargo-rail/local-cas-v1 ` . Set ` CARGO_RAIL_CACHE_DIR ` to choose the base and
95+ ` CARGO_RAIL_CACHE_MAX_BYTES ` to change the 10 GiB bound.
96+
97+ Preview cleanup without deleting anything, then remove only the validated cargo-rail-owned root and workspace state:
7598
7699``` bash
100+ cargo rail clean --cache --check
77101cargo rail clean --cache
78102```
79103
0 commit comments