Repository navigation
Shard-A: compile-gate partition totality + cross-shard seam preservation proof - #6290
Conversation
The orphan check (glob paths absent from roster) had no counterpart for roster entries absent from the glob output, so a stale/phantom roster path could false-green as PartitionTotal. Add PartitionSurplusClaim and a synthetic witness proving it reds.
|
Addressing review 35760: Finding 1 (partition totality one-sided, dag_compile_clean_shard_totality.dag:45-50) — valid, fixed in 3b337f0. Finding 2 (fragile substring exit-code parsing, dag_compile_clean_seam.dag:27-28) — not reproducible, no change. — sent from jolly-ram-333 |
|
Addressing review 35752: Finding A (RawLine medium-as-string scaffold missing typed Disposition, dag_compile_clean_seam_transport.dag) — valid, fixed. Finding B (missing realization_vocab_exception_roster entries) — valid, fixed. All of the above pre-existing debt uncovered along the way (3 files in — sent from jolly-ram-333 |
|
Addressing review 35762: Finding (missing Disposition scaffold on dag_compile_clean_shard_totality_transport.dag) — valid, fixed in 8fd294e. — sent from jolly-ram-333 |
|
Re: CI FAILING @ 126d318. Investigated both failing jobs — this is the pre-existing tree-wide infra outage, not a regression from this PR's diff:
Cross-checked No fix pushed since there's nothing in this diff to fix; this branch merges — sent from jolly-ram-333 |
Worker attestation
Closes #N— this is an ad-hoc shard-A work item, not a GitHub issue.origin/mainplus my own commits; verifiedgit diff --stat origin/mainshows only the 7 files below).Summary
Builds on #6118's partition/verdict-compose algebra (
dag/tools/dag_compile_clean_partition.dag, reused not duplicated) with two by-execution proofs for the compile-gate shard partition:Partition totality (
dag_compile_clean_shard_roster.dag,dag_compile_clean_shard_totality*.dag) — proves every module in the livedag/corpus (885 files) is claimed by exactly one shard: no orphan, no double-claim. The roster is built from the real host builtinmodule_declaration_facts(bypassing the currently-brokenv2.lens.module_graph.dag, which Affected-set Step 3: module-grain frontier equivalence receipts #6274 is fixing separately — not a dependency here, per the brief). Ground truth is an independentfind dag -name '*.dag' | sortrun viashell.Exec.Run, not just a re-derivation from the same source — the two are compared and any orphan/dup/glob-failure fails closed to a typed, locatedPartitionOrphan/PartitionDuplicateClaim/PartitionGlobUnavailableverdict, never silence.Cross-shard seam preservation (
dag_compile_clean_seam*.dag) — deliberately breaks a real cross-shard import edge (dag/std/bit.dagimportsClassicalfromdag/std/logic.dag) by renaming only the type declaration in a scratch copy of the tree, leavinglogic.dag's own usages of the old name untouched. This proves by execution that: (i) shard Y (logic.dag) reds with a located diagnostic, (ii) shard X (bit.dag, the importer) also reds — the seam's consequence is not silently lost — and the composed verdict (via compile-clean shard A: partition boundary, one-shard receipt, compose proof #6118'scompose_compile_clean_shard_verdicts) reds and names the cause, and (iii) the full monolith compile run as a control emits the same diagnostic class (Classical) as both shards, confirming no diagnostic class is uniquely available to the monolith and missing from the sharded path.Both witnesses run against the real 885-module
dag/tree (not synthetic fixtures) viashell.Exec.Run; synthetic-input algebra witnesses are included too as fast unit-style checks, but are not a substitute for the live-tree proof.Explicitly out of scope
Wiring this partition into
ci_floor_planis not part of this PR. Floor wiring is gated on the in-process shard resolve pool (M2) — re-landing per-PR floor wiring before that lands regressed CI by 30.9x (see the #6127/#6156 receipt trail). This PR is proof-of-partition only.Test plan
Locally built
gunbcin-tree (ctrl-build --local -- cargo build -p v1-compiler --release --bin gunbc) — a pre-installed binary resolvesworkspace_root()against a different checkout and silently returns wrong (not errored) results, so all witnesses below ran against that local binary:compile_clean_shard_roster_is_well_formed→truecompile_clean_shard_totality_transport_serializes_find_sort→truecompile_clean_shard_totality_algebra_holds→truecompile_clean_shard_totality_holds_on_live_tree→true(realfind dag -name '*.dag' | sortexecuted viashell.Exec.Run, compared against the live 885-module roster)cross_shard_seam_transport_serializes_expected_shape→truecross_shard_seam_algebra_holds→true(synthetic-receipt algebra, including two fail-closed negative cases)cross_shard_seam_preservation_holds_on_live_tree→true, run twice (pre- and post- merging latestorigin/main): whole-dag/-tree scratch copy, single-line perturbation oflogic.dag, three realgunbc compileinvocations (shard Y alone, shard X alone, full monolith control) with captured stdout/stderr/exit codesAll via
gunbc run --claim-runagainst the real worktree, notgunbc compile's typecheck-only path.