Skip to content

Rows 4+5+8+9: Int-literal-into-branded-string (4), type alias materialised twice (3), record literal through shared-wrapped alias (1), type annotations needed (1) — nine sites, four root packets - #8552

Merged
briansrls merged 5 commits into
mainfrom
session/neat-owl-140
Aug 20, 2026

Conversation

@gunbai-bot

@gunbai-bot gunbai-bot Bot commented Aug 19, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Rows 4/5/8/9 from the materialization_carriers census (Int-literal-into-branded-string ×4, type alias materialised twice ×3, record literal through shared-wrapped alias ×1, type annotations needed ×1 — nine sites, four root packets). Landed in fc71808 (widen OperatorObserved.observed_at, dedup row9 generic-inference workaround) and 124c770 (fix OccurrenceId consumers to import from std.occurrence_identity instead of v2.std.node).

Re-measurement (2026-08-20, self-run, not relayed)

Instrument: census's own repro (gunbc compile --source-root dag --source-root src/v2 --entry src/v2/compiler/materialization_carriers.dag --target rust --dependency-pool-index primary-precedence, then cssl_assemble, then CSSL_STD_SEED_LINK=1 cargo build --release --lib --message-format=json, errors counted at (code, primary span) grain from the JSON stream). One gunbc/cssl_assemble binary pair built once (release, sha256 44b96398... / 6d395082...) and invoked by absolute path for both arms — never rebuilt between arms.

Arm A — main alone, a6ca6882d18114b52532c0804dc89f97b441f493:

  • 41 total errors (matches the census's current N=41 baseline)
  • Histogram: E0308 15 · E0277 13 · E0599 4 · E0425 3 · E0369 2 · E0310 2 · E0560 1 · E0282 1
  • All 9 of my rows' sites present and unchanged from the census board:
    • row4: extdeps_realization_compile_stage_memo.rs:96,102, extdeps_realization_parse_table_memo.rs:117,123 (4× E0308)
    • row5: v2_std_node.rs:69,78,84 (84 carries 2 diagnostics)
    • row8: std_verification.rs:22 (E0560)
    • row9: std_realization_measurement.rs:197 (E0282)
  • 9 distinct row-site keys present.

Arm B — main + this branch merged into a scratch copy (not pushed), same SHA base, same binaries:

  • Merge was clean (27 files touched inside the compile closure — auto-merge, no conflicts).
  • 30 total errors (-11 vs Arm A)
  • Histogram: E0277 13 · E0308 6 (-9) · E0599 4 · E0425 3 · E0369 2 · E0310 2 · E0560 0 (-1) · E0282 0 (-1)
  • 0 distinct row-site keys remaining — all 9 sites across rows 4/5/8/9 are gone.

Row 9 in particular is confirmed still live and still removed by this branch as of this SHA, despite sitting downstream of an in-flight Clone-bound-derivation change elsewhere in the census (per smart-ram-730) — that change had not altered this site as of a6ca6882d18.

Conclusion: the fix is still live and still complete against current main. No re-cut needed.

Test plan

  • Four-arm remeasurement above, run by this session directly (not relayed from the census owner), against main@a6ca6882d18114b52532c0804dc89f97b441f493, one binary pair built once and invoked by absolute path for both arms.
  • Mirror-contamination check (git merge-base --is-ancestor 98d7147f9e <merge-base>) confirmed CLEAN.
  • Mirror-drift detector (git diff origin/main...HEAD --stat -- src/v1/stage0/src/) confirmed clean (no output).

Correction (2026-08-20, follow-up): the eleventh diagnostic, and a script bug

smart-ram-730 caught that my reported delta (-11) didn't reconcile against my named rows (10, using my earlier per-site count). Diffed both arms' full diagnostic lists by (code, primary file, primary line) rather than by site-presence, same binaries/SHAs as above. Findings:

  1. Script bug in my first pass: the per-site counter iterated every span on a diagnostic, not just the primary one, which double-counted v2_std_node.rs:84 and made row5 look like 4 diagnostics across 3 sites. Corrected: row5 is exactly 3 E0308 (v2_std_node.rs:69,78,84), matching the census board. My "9 distinct row-site keys" claim above is unaffected (site-grain, not diagnostic-grain), but the per-row diagnostic counts I gave for row5 should read 3, not 4.

  2. The real eleventh (and twelfth): two E0308s at extdeps_uri.rs:752,756 also disappeared between the two arms — genuinely removed, not a line-shift artifact. These belong to census row 2 ("Optional carrier fork"), not to this packet's rows 4/5/8/9. Correction (2026-08-20): these 2 sites are NOT already gone at a6ca6882d18 alone — arm A (main alone) has all 6 of row 2's sites present, confirmed by the E0308 histogram (15 = row4 4 + row5 3 + row2 6 + 2 others). They are removed only once this branch merges. Accurate framing: two of row 2's six sites will be removed by Rows 4+5+8+9: Int-literal-into-branded-string (4), type alias materialised twice (3), record literal through shared-wrapped alias (1), type annotations needed (1) — nine sites, four root packets #8552 once it lands — a fact for row 2's owner to act on after this merges, not a state true of main today. Routing to row 2's owner is smart-ram-730's, not mine.

  3. Ruled out as a mask: std_cache_interface.rs:638,695,699,703 (row 2's other 4 sites) also disappear from the raw diff, but reappear one line earlier (637,694,698,702) — same 4 diagnostics, shifted by an unrelated one-line change elsewhere in that emitted file from the merge. Net effect on that file: zero. Not a collateral fix, not a mask — a diff artifact, confirmed by the shift being contiguous.

Reconciled: 9 (rows 4/5/8/9, corrected) + 2 (row 2 collateral, extdeps_uri.rs) = 11. Matches the measured delta exactly.

gunbc-ci-auto-heal and others added 5 commits August 19, 2026 17:10
…plicate alias dedup, shared-wrapped alias construction, fold type inference

Row 4: OperatorObserved.observed_at is LogicalTime (branded NonEmptyStr);
replace the placeholder Int literal 0 with a dated string, matching the
sccache.dag convention, in compile_stage_memo.dag and parse_table_memo.dag.

Row 5: src/v2/std/node.dag re-aliased std.occurrence_identity.OccurrenceId
under a local name, materializing a second nominal type in emitted Rust.
Delete the local alias; reference the shared type directly, updating the
two downstream test consumers.

Row 8: dag/std/verification.dag independently re-declared
NanosecondDuration = Measure<Time, Nano, Nat> — an exact duplicate of the
existing std.measure.Nanosecond alias for the same generic instantiation,
the same duplicate-authority mechanism as row 5. Delete the duplicate and
its wrapper fns; consume std.measure.Nanosecond/nanosecond/nanosecond_count
directly, propagating the rename through every consumer module and test.

Row 9: dag/std/realization_measurement.dag's time_measure_list_total folded
a raw Nat accumulator via + with a literal 0 init, leaving Nat's algebraic
type unpinned for inference. Fold over typed Measure values via
time_measure_seq instead, mirroring the sibling time_measure_list_par.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…w9 generic-inference workaround

CacheRowEvidence.OperatorObserved.observed_at was a LogicalTime carrying a
0 sentinel for "never observed" since its original authoring (verified via
git log --follow across all 7 consumer files: no commit ever set a real
date on these rows) -- a state-space conflation between "no observation"
and "observed at time 0". Widened to Optional<LogicalTime> (v2.std.optional)
and every OperatorObserved consumer in dag/extdeps/realization/ moved to
Absent, so the type now states the true absence rather than encoding it as
a fabricated timestamp. RunnerObserved (sccache.dag, genuine non-sentinel
dates) is untouched.

witness_measured_rollup_differs_from_predicted_zero in
realization_measurement.dag avoided a broken generic type-inference path
(the .dag-level let-annotation on a generic call is dropped by the rust
emitter) by comparing the measured count directly against the literal 0,
matching the idiom already used elsewhere in the same function, instead of
round-tripping through cost_account_predicted_zero().

Both changes verified via per-module compile probe
(docs/probes/curated_cargo_probe_one.sh); remaining diagnostics on the
touched extdeps/realization files (ProviderRetention namespace resolution,
cache_interface.dag's pre-existing .first().cloned() Option/String
mismatches) are confirmed pre-existing and unrelated -- reproduced
identically with these changes stashed out.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…t v2.std.node

Row 5's dedup of the local OccurrenceId alias in src/v2/std/node.dag (fully
qualifying std.occurrence_identity.OccurrenceId in place) removed the symbol
that six downstream modules were importing as v2.std.node's own export:
src/v2/compiler/03_resolve.dag, src/v2/std/dependents.dag,
src/v2/compiler/02_parse.dag, src/v2/std/provenance.dag,
src/v2/extdeps/languages/dag.dag, src/v2/std/occurrence_id.dag.

CI (PR #8552, run 32290711061) caught this as required-floor resolve
refusals: "name 'OccurrenceId' not found in module 'v2.std.node'" across
all six. Root fix per single-authority (DESIGN.md §3): repoint each
consumer's import to OccurrenceId's real home, std.occurrence_identity,
rather than re-adding a re-export alias to node.dag. Verified via
`gunbc compile --target rust` on each file: all resolve past
compile.reconcile with zero OccurrenceId-related diagnostics.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor Author

Status: rows 4/5/8/9 all complete and pushed (124c770). Confirmed rows 4/9 via stash-baseline control (pre-existing/unrelated errors only), row 5's OccurrenceId import fix verified via gunbc compile on all 6 consumer files.

CI's "witnesses" job is red, but not from this diff: required-floor on this PR's head reports the exact same failed=2 as main's own latest completed run (0c7b916, run 32290602208) — same two tests (test.claim.live_deploy.emit.witness_scripts_stay_within_ci_runner_grants, v2.test.lens_inert_carrier.inert_carrier_test.inert_carrier_no_unrostered_or_stale), identical planned=9683 passed=9375 known_red_held=306. Neither test is in this PR's diff closure (no OccurrenceId, node.dag, cache_interface.dag, or optional-modeling references).

This is a fleet-wide pre-existing red (candidate causes traced to #8567 and #8503, per smart-ram-730), not owned by this PR. Not watching for main to go green — merges when main is fixed or the operator merges past it.

@gunbai-bot
gunbai-bot Bot marked this pull request as ready for review August 20, 2026 16:07
@briansrls
briansrls merged commit a4677f3 into main Aug 20, 2026
0 of 2 checks passed
@briansrls
briansrls deleted the session/neat-owl-140 branch August 20, 2026 17:14
gunbai-bot Bot pushed a commit that referenced this pull request Aug 20, 2026
…CI paragraph

DESIGN.md and its authority `gunbc.design_document` conflicted in the CI rung-drop
paragraph, and both sides had added something real:

  theirs  a new clause: `executed` counts a witness REACHING the fold, not its
          assertion running — the hermetic boundary, with the rationale that
          mocking the refusal would pass such a witness against a fabricated exit
          status
  ours    the invocation is now `--required-ci`, and the flag clause records that
          the two regen steps were re-added and CONSOLIDATED the same day

Resolved by starting from THEIRS and re-applying my two edits onto it, so main's
new clause survives verbatim rather than being reconstructed from memory. Verified
by content — five distinct phrases, two mine and three theirs, each present
exactly once. Not by `grep -c`: this file is one giant `li(text: "...")` line, so
a line count returns 1 whatever the paragraph contains, which is the prose-grep
trap that already cost me a shipped mutation on this branch.

DESIGN.md itself was REGENERATED from the resolved authority rather than
hand-merged — it is a generated artifact, and hand-resolving it would author the
projection instead of deriving it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant