Skip to content

Unbreak v1 self-resolution: kill the undead fold-init-none in 04_resolve (filter/first, the #6250 shape) - #6291

Merged
briansrls merged 9 commits into
mainfrom
sharp-deer-310/fix-resolve-fold-init-none
Jul 5, 2026
Merged

briansrls merged 9 commits into
mainfrom
sharp-deer-310/fix-resolve-fold-init-none

Conversation

@briansrls

@briansrls briansrls commented Jul 5, 2026 •

Copy link
Copy Markdown
Contributor

What (narrowed after review — see thread)

One fix: src/v1/04_resolve.dag — resolve_paramless_generic_use_decl_with_children carried the Optional-fold-init class (fold(init: none) + acc != none): 2 hard diagnostics (if branches resolve to incompatible types: Product(Unit) vs Product(Node)), blocking ALL resolution of the v1 corpus, and with it regen, the re-measure, and cutover #1. Rewritten to #6250's proven filter/first shape — identical semantics (first parent whose str_bindings entry is parameterized wins; same structural-name and decl fallback arms), no Optional accumulator.

Deliberately NOT in this PR: registering test_claim_ownership_movable.rs. With resolution fixed, --verify advances to the emission wall and fail-closes with a typed refusal naming that file (src/v1/ownership_movable_test.dag entered the regen sweep via the ownership lane with no regen receipt). Cursor's review correctly rejected registering it without committing the emission (spec-without-execution), and the commit path was then refuted by execution: the fresh-emitted file calls fresh sibling signatures (5× E0061 against the committed crate), so committing it drags in its dependency drift — which is the full cutover. Resolution: the typed refusal stands as the honest interim; registration + emission land together in cutover #1 (the cutover worker's brief carries this).

The undead-bug archaeology (why this keeps happening)

This exact pattern at this exact site: introduced #6235 → fixed #6250 → re-introduced #6239 (inline) → preserved through #6280's helper refactor. Fixed once, resurrected twice, surviving a merge and a rewrite — because nothing executes src/v1 resolution at merge time. Fifth dark-regen break this week counting the ownership-lane registration miss. This is the standing case for the two-stage merge-norm (interim: local regen self-compile receipt on corpus-touching PRs; durable: regen-in-affected-set-CI) — co-signed by cool-hawk-899, awaiting operator ruling.

Addendum — the case in miniature (via cool-hawk-899)

Dark break #5 is self-demonstrating: src/v1/ownership_movable_test.dag — the corpus add that slipped an unregistered emission past merge — is the same file cool-hawk-899's #6289 (merged) honesty-marks as "not resolvable / off-discovery." The norm violation and the manual honesty-note are one file. #6289's marker gets its 1-line reconciliation follow-up after this merges.

Receipts (by execution, regen_stage0 --verify)

  • Before (broken main): 2 hard diagnostics at the fold site.
  • After this fix: 0 hard diagnostics; verify advances to the emission wall → typed refusal: fresh self-compile emitted unregistered stage0 file(s): test_claim_ownership_movable.rs — the honest, countable interim until cutover Add SVG viz, test helpers, and makegen scaffold #1.
  • Registration-without-commit and commit-without-cutover both tested and rejected (read-error / 5× E0061 respectively); roster stays 92 with the partition intact.

🤖 Generated with Claude Code

Brian Searls and others added 3 commits July 5, 2026 15:41
… resolve_paramless_generic_use_decl_with_children + register test_claim_ownership_movable emission

Two dark-regen breaks fixed, receipts by execution (regen_stage0 --verify):
(1) The Optional-fold-init class (fold init:none + acc != none) that #6250 fixed was re-introduced by #6239 inline and preserved through #6280's helper refactor — 2 hard diagnostics (if-branches Product(Unit) vs Product(Node)), blocking ALL v1 resolution. Rewritten to #6250's proven filter/first shape, identical semantics (first parent whose binding is parameterized wins; same fallback arms). After: 0 hard diagnostics.
(2) With resolution restored, verify reached the emission wall and fail-closed on unregistered test_claim_ownership_movable.rs (src/v1/ownership_movable_test.dag, added by the ownership lane without a regen receipt). Registered in GENERATED_STAGE0_FILES + stage0_emit_model mirror + witness pin 92->93 (test artifacts in the roster have precedent: compiler_tests.rs, wt_a/wt_b). After: 0 unregistered; --verify reaches byte-compare, red only on the known cutover backlog (including this file's missing committed counterpart, written at cutover #1).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@gunbai-bot gunbai-bot Bot changed the title continue work on v1 burn down Unbreak v1 self-resolution: kill the undead fold-init-none in 04_resolve + register ownership_movable emission Jul 5, 2026
@gunbai-bot
gunbai-bot Bot marked this pull request as ready for review July 5, 2026 15:57
Brian Searls and others added 2 commits July 5, 2026 16:07
… (refuted by execution — emitted file needs fresh sibling signatures, 5x E0061 vs committed crate; registration+emission land together at cutover #1)

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

gunbai-bot Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

Both findings verified and acted on — resolution went your way twice over: (1) Registration-without-commit: CONFIRMED spec-without-execution — --verify reads every registered file from the committed tree and the missing file surfaces as a read error, not a drift row. (2) Your proposed alternative (land the regen commit for the file + lib.rs row) was then TESTED BY EXECUTION and refuted: the fresh-emitted test_claim_ownership_movable.rs calls fresh sibling signatures and fails 5× E0061 against the committed crate — committing it pulls in its dependency drift, which is indistinguishable from doing the full cutover. So the PR is narrowed to the 04_resolve fix alone (f3b91bb: registration dropped, roster back to 92, emitted file removed); the typed unregistered-file refusal at the emission wall stands as the honest interim, and registration + emission land together in cutover #1 (already in the cutover worker's brief). Body updated to match.

— sent from sharp-deer-310

Brian Searls and others added 2 commits July 5, 2026 16:09
…hotfix)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… with cutover #1)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@gunbai-bot gunbai-bot Bot changed the title Unbreak v1 self-resolution: kill the undead fold-init-none in 04_resolve + register ownership_movable emission Unbreak v1 self-resolution: kill the undead fold-init-none in 04_resolve (filter/first, the #6250 shape) Jul 5, 2026
@gunbai-bot

gunbai-bot Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

Head churn note for reviewers/operator: commit 6f4c02c was NOT authored content — the worktree auto-WIP sweep captured a temporary state from a diagnostics experiment (main's broken 04_resolve checked out to reproduce the write-mode fail-open seam, receipt in the seam work item) and pushed it onto this branch, silently un-fixing the PR. 4e65b4a reverts it. Net diff vs main is again exactly the reviewed content: the 18-line filter/first fix in src/v1/04_resolve.dag, nothing else. Both approvals (claude, cursor) were given for this exact net diff.

— sent from sharp-deer-310

@gunbai-bot

gunbai-bot Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

CI note (this head and any future ones): rust_tests passes (46s). The ci job red is the floor capacity condition under the CURRENT deployed budgets (#6279/#6280 raised them post-#6273: job 65m, compile-clean floor step 40m) — this run spent ~9m building then the floor step consumed its full 40-minute budget and failed loudly at the step, which is the intended §5 semantics. The diff (18 lines of .dag resolution fix) cannot reach the floor's timeout cause; content receipts are in the PR body (regen_stago0 --verify: 2 hard diagnostics → 0). Floor-fits-CI remains the §2 compile-clean/affected-set lane's deliverable, not this PR's.

— sent from sharp-deer-310

briansrls added a commit that referenced this pull request Jul 5, 2026
One new registry intrinsic trace_mark(label) -> Unit (the
record_source_chars_index_lookup precedent: registry row in 04_method.dag,
realization in runtime_rust.dag -> v1_rt, interpreter arm for totality).
Nine marks at the known segment boundaries of the compile pipeline
(frontend/normalize/reconcile/analyses/emit begin+done, dag collect/serialize),
so every run log carries a natural Gantt:

  [gantt] compile.reconcile.done t_ms=... rss_mib=...

Consecutive marks define the segments; rss_mib rides along for the memory
curve. Motivation: the whole-tree compile runs >60 min single-threaded with
zero output after "resolved N sources" — CI runs die inside it blind
(operator request 2026-07-05: checkpoints + a general logging system).

Marked bridge, interim by design: dissolves into the v2 per-RealizedStep
CostAccount (std.realization_measurement) when the realization-measurement
carrier is inhabited. Authority edits (.dag) land with hand-synced generated
seed (.rs) per the #5867 precedent — regen is currently blocked on main
(#6291); re-verify at the next regen window.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@briansrls
briansrls merged commit da996f7 into main Jul 5, 2026
2 of 3 checks passed
@briansrls
briansrls deleted the sharp-deer-310/fix-resolve-fold-init-none branch July 5, 2026 20:55
gunbai-bot Bot pushed a commit that referenced this pull request Jul 5, 2026
Regen broken (#6291); .dag prepass without hand-synced .rs is parallel
representation. Keep only ancestry-cache sharing + dissolution trigger.

Co-authored-by: Cursor <cursoragent@cursor.com>
briansrls added a commit that referenced this pull request Jul 5, 2026
#6298)

* WIP: ci timeout investigation

* trace_mark: stage-boundary gantt marks through the v1 compile pipeline

One new registry intrinsic trace_mark(label) -> Unit (the
record_source_chars_index_lookup precedent: registry row in 04_method.dag,
realization in runtime_rust.dag -> v1_rt, interpreter arm for totality).
Nine marks at the known segment boundaries of the compile pipeline
(frontend/normalize/reconcile/analyses/emit begin+done, dag collect/serialize),
so every run log carries a natural Gantt:

  [gantt] compile.reconcile.done t_ms=... rss_mib=...

Consecutive marks define the segments; rss_mib rides along for the memory
curve. Motivation: the whole-tree compile runs >60 min single-threaded with
zero output after "resolved N sources" — CI runs die inside it blind
(operator request 2026-07-05: checkpoints + a general logging system).

Marked bridge, interim by design: dissolves into the v2 per-RealizedStep
CostAccount (std.realization_measurement) when the realization-measurement
carrier is inhabited. Authority edits (.dag) land with hand-synced generated
seed (.rs) per the #5867 precedent — regen is currently blocked on main
(#6291); re-verify at the next regen window.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* WIP: ci timeout investigation

* WIP: ci timeout investigation

---------

Co-authored-by: Brian Searls <briansrls@gunb.ai>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
briansrls pushed a commit that referenced this pull request Jul 5, 2026
* build_type_env: borrow parent cache str_bindings on single-import chains

Replace map_merge(parent.ancestry_str_bindings, parent.str_bindings) with
parent.type_env_cache.str_bindings (Rc share). Multi-import path unchanged.

Co-authored-by: Cursor <cursoragent@cursor.com>

* fix: pull unsynced SymbolIndex prepass from ancestry PR (#5867)

Regen broken (#6291); .dag prepass without hand-synced .rs is parallel
representation. Keep only ancestry-cache sharing + dissolution trigger.

Co-authored-by: Cursor <cursoragent@cursor.com>

---------

Co-authored-by: Brian Searls <briansearls1@gmail.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
briansrls added a commit that referenced this pull request Jul 6, 2026
…ges (byte-identical, width=1) (#6306)

* WIP: ci timeout investigation

* trace_mark: stage-boundary gantt marks through the v1 compile pipeline

One new registry intrinsic trace_mark(label) -> Unit (the
record_source_chars_index_lookup precedent: registry row in 04_method.dag,
realization in runtime_rust.dag -> v1_rt, interpreter arm for totality).
Nine marks at the known segment boundaries of the compile pipeline
(frontend/normalize/reconcile/analyses/emit begin+done, dag collect/serialize),
so every run log carries a natural Gantt:

  [gantt] compile.reconcile.done t_ms=... rss_mib=...

Consecutive marks define the segments; rss_mib rides along for the memory
curve. Motivation: the whole-tree compile runs >60 min single-threaded with
zero output after "resolved N sources" — CI runs die inside it blind
(operator request 2026-07-05: checkpoints + a general logging system).

Marked bridge, interim by design: dissolves into the v2 per-RealizedStep
CostAccount (std.realization_measurement) when the realization-measurement
carrier is inhabited. Authority edits (.dag) land with hand-synced generated
seed (.rs) per the #5867 precedent — regen is currently blocked on main
(#6291); re-verify at the next regen window.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

---------

Co-authored-by: Brian Searls <briansrls@gunb.ai>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
briansrls added a commit that referenced this pull request Jul 6, 2026
…ges (byte-identical, width=1) (#6306)

* WIP: ci timeout investigation

* trace_mark: stage-boundary gantt marks through the v1 compile pipeline

One new registry intrinsic trace_mark(label) -> Unit (the
record_source_chars_index_lookup precedent: registry row in 04_method.dag,
realization in runtime_rust.dag -> v1_rt, interpreter arm for totality).
Nine marks at the known segment boundaries of the compile pipeline
(frontend/normalize/reconcile/analyses/emit begin+done, dag collect/serialize),
so every run log carries a natural Gantt:

  [gantt] compile.reconcile.done t_ms=... rss_mib=...

Consecutive marks define the segments; rss_mib rides along for the memory
curve. Motivation: the whole-tree compile runs >60 min single-threaded with
zero output after "resolved N sources" — CI runs die inside it blind
(operator request 2026-07-05: checkpoints + a general logging system).

Marked bridge, interim by design: dissolves into the v2 per-RealizedStep
CostAccount (std.realization_measurement) when the realization-measurement
carrier is inhabited. Authority edits (.dag) land with hand-synced generated
seed (.rs) per the #5867 precedent — regen is currently blocked on main
(#6291); re-verify at the next regen window.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

---------

Co-authored-by: Brian Searls <briansrls@gunb.ai>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
briansrls added a commit that referenced this pull request Jul 6, 2026
* WIP: dedup dag.dag mvp1 fn families into parameterized cores

* WIP: dedup dag.dag mvp1 fn families into parameterized cores

* Dedup dag.dag mvp1 fn families into parameterized cores.

Collapse five repeated stamping clusters (arrow-with-body nodes, target-model bundles, grammar token sequences, grammar-relation rows, statement prefix tokens) into shared parameterized cores with thin per-family wrappers, preserving explicit control-fixture operands at instance sites.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Demand-driven realize: typecheck as memoized recursion over import edges (byte-identical, width=1) (#6306)

* WIP: ci timeout investigation

* trace_mark: stage-boundary gantt marks through the v1 compile pipeline

One new registry intrinsic trace_mark(label) -> Unit (the
record_source_chars_index_lookup precedent: registry row in 04_method.dag,
realization in runtime_rust.dag -> v1_rt, interpreter arm for totality).
Nine marks at the known segment boundaries of the compile pipeline
(frontend/normalize/reconcile/analyses/emit begin+done, dag collect/serialize),
so every run log carries a natural Gantt:

  [gantt] compile.reconcile.done t_ms=... rss_mib=...

Consecutive marks define the segments; rss_mib rides along for the memory
curve. Motivation: the whole-tree compile runs >60 min single-threaded with
zero output after "resolved N sources" — CI runs die inside it blind
(operator request 2026-07-05: checkpoints + a general logging system).

Marked bridge, interim by design: dissolves into the v2 per-RealizedStep
CostAccount (std.realization_measurement) when the realization-measurement
carrier is inhabited. Authority edits (.dag) land with hand-synced generated
seed (.rs) per the #5867 precedent — regen is currently blocked on main
(#6291); re-verify at the next regen window.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

* WIP: ci timeout investigation

---------

Co-authored-by: Brian Searls <briansrls@gunb.ai>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>

* Delete flaky test disposition_kernel_aligns_on_discriminator_fixture (#6324)

This sole test in mod floor_disposition_kernel_alignment (cli_run.rs) ran the
floor-disposition analysis, which typechecks the gunbc module closure live — and
that hits the #6239 compile-wall: per-module typecheck attribution measured
gunbc.ci_deploy_access at 416s (7 min) for a single module, with the test spending
>9 min and never finishing. It was the sole reason `cargo test --workspace` appeared
to hang (deterministic, single-threaded reproducible), compounded by its
std::env::set_current_dir cwd-mutation racing under parallel execution (#5971 class).

No value and slated for deletion (operator, 2026-07-06). Floor-disposition coverage
is exercised in the floor; the real fix is the compile-wall itself (owned elsewhere).

Co-authored-by: Brian Searls <briansrls@gunb.ai>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Brian Searls <briansrls@gunb.ai>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: gunbai-bot[bot] <289086189+gunbai-bot[bot]@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <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