Skip to content

move off of claim executor - #9399

Closed
gunbai-bot[bot] wants to merge 1 commit into
mainfrom
verify-cm470
Closed

gunbai-bot[bot] wants to merge 1 commit into
mainfrom
verify-cm470

Conversation

@gunbai-bot

@gunbai-bot gunbai-bot Bot commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

Auto-opened by session-dashboard for session merry-bear-547.
Pushing to verify-cm470 advances this PR.

Worker attestation

Before flipping this PR to ready for review, confirm each item:

  • Title describes the change (not the session id or branch).
  • PR body summarises what and why (replace the TODO below).
  • Tests run: name the command (e.g. npm test, cargo test) and the result.
  • If this closes a work item, the body contains a Closes #N directive.
  • No commits on this branch are surprises (no fork/cherry-pick I did not make).
  • No secrets / credentials / large binaries staged.

Summary

TODO: replace this paragraph with one or two sentences naming the change and its motivation. Reviewers read this first.

Test plan

  • TODO: list the commands that ran (or "no tests changed; relied on CI") and the outcome.

…collapsed into one global bare slot

`fn_nodes` holds ONE bare-name slot per spelling plus one qualified slot per
declaration, and `lookup_fn` is a plain map get with no caller context. Two
modules that both declare `section_1` therefore fight over a single entry, and
the loser's OWN calls execute the winner's body with no diagnostic anywhere.

THE SILENT FACE SHIPPED. Four plan carriers in dag/gunbc/plans each declare
`status_block` and `section_1` .. `section_9` and each folds its body by calling
them BARE -- import_namespace_program, v2_corpus_self_host,
branch_merge_admission_model, wave2_prep_design. One carrier won all ten slots,
so import-namespace-program.md was emitted carrying v2-corpus-self-host's entire
body under its own title and slug: a well-formed markdown file, byte-stable
across runs, with nothing refusing.

WHY IT WAS INVISIBLE: the type layer already resolves per module
(`lookup_resolved_sig` tries the module's own `local` before `parents`), so
typecheck bound each carrier's calls to its own sections and only the runtime
collapsed them. The collision was even COMPUTED -- `ambiguous_bare_function_names`
-- and `lookup_fn` never consulted it.

THE FIX: `lookup_fn_from(name, site_file)` resolves a bare name claimed by more
than one module to the referring file's OWN module first, then falls through to
the shared slot. Wired at `eval_call` and both `eval_var` tiers, with a new
`file_module_paths` index built in the walk that was already visiting every item.

SCOPE, GATED DELIBERATELY. The tier fires only for names in
`ambiguous_bare_function_names`, so the resolution of every name exactly one
module declares is byte-for-byte what it was; only the colliding population
moves, and it moves toward the module that authored the reference.

WHAT IS NOT CLAIMED. This is not the namespace program. A bare reference to a
name the referring module does NOT declare, claimed by two OTHER modules, is
still picked by walk order with nothing said -- that residue stays counted in
`PreparedClaimScope::ambiguous_bare_names`, whose doc is corrected here: the
count is unchanged and its SUBJECT has narrowed, so a reader taking it as the
silent-pick population would now overcount. The terminal wall is namespace-only
resolution, where ambiguous bare binding has no constructor.

EVIDENCE, MEASURED A/B ON ONE REMOTE DISPATCH rather than predicted. An owned
fixture pair (sentinels 100/200, structurally identical so neither peer is
privileged by anything the author wrote) plus a witness asserting BOTH
directions in one row: exactly one bare slot exists, so under the defect at
least one conjunct is false whichever peer won, which makes the conjunction
order-independent where a single-direction row would be a coin flip.

    fix applied:  main row true,  control true
    fix reverted: main row FALSE, control true

The control asserts bare CROSS-module references still resolve -- the direction
a repair that narrowed resolution instead of ordering it would break.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Aug 27, 2026

Copy link
Copy Markdown
Contributor Author

Closing — this is not a change. verify-cm470 is a local verification branch I created to build gunbc from crisp-moth-470's fix and check it end-to-end; it was auto-attached as a PR before I had pushed anything of my own to it.

Its head (e325e32873a) is crisp-moth-470's commit verbatim. The real PR for that work is #9393, which carries the same commit on session/crisp-moth-470 along with its witness and fixtures. Two PRs proposing one commit is the duplicate-authority shape this repo refuses, and the one to keep is the authored branch, not my scratch checkout.

Nothing is lost by closing this: no commit here is absent from #9393.

What I was using the branch for is worth stating, since it is still in flight and is a claim #9393 does not itself make. That PR's witness proves interpreter behavior — two modules declaring the same bare name each reach their own declaration. It does not prove that the shipped artifact is repaired, which is a separate question: the fix could order resolution correctly while the projection path still emits a wrong body for some other reason. I am regenerating both plan projections from a binary built on that commit to confirm docs/plans/import-namespace-program.md comes back carrying its own section 1 ("The end state") rather than v2-corpus-self-host's ("The goal, and what it buys"), and that the two files' body hashes now differ. Result goes on #9393.

— sent from merry-bear-547

@gunbai-bot gunbai-bot Bot closed this Aug 27, 2026
@gunbai-bot
gunbai-bot Bot deleted the verify-cm470 branch August 27, 2026 03:21
@gunbai-bot gunbai-bot Bot mentioned this pull request Aug 27, 2026
6 tasks
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.

0 participants