Repository navigation
affected_set frontier receipts: observe Map by application, not whole-frontier == - #4560
Merged
Merged
Conversation
…-frontier ==
Triage of the runtime-false affected_set frontier receipts (excluded_propagation_proof,
irt1_excluded_propagation_receipt, and the same-root-cause dimension_seed receipts).
Root cause is the BROADER map-equality substrate, NOT local mark_excluded/mark_rerun:
ReExecFrontier.decisions is a std `Map<K,V>` which IS a PartialFunction
(v4.std.collection: `lookup: fn(K) -> Witness<V>`). Over structural (non-String) keys
the v2 runtime drops out of the native `Value::Map` (HashMap<String,Value>) fast path —
the `map_insert` builtin only matches `Value::Str` keys — and lands on the closure/record
form `Map { lookup: fn... }`. `PartialEq for Value` has no closure arm, so any two such
maps compare `_ => false`, even a value vs. itself. Probed: empty-map == TRUE, but
single-entry structural-key map == itself FALSE; key/proof/Node value equality all TRUE.
So mark_excluded local logic is correct; the receipts asserted an UNDECIDABLE equality.
Fix (model-correct, test-only): a PartialFunction is observed by application. New shared
helper frontier_observation.frontier_decision_matches looks the seeded key up via map_get
and compares the resolved FrontierDecision (a coproduct over lists/records, which DO
compare structurally). The four receipts now run green AND discriminating (perturbing
Excluded.rest or the expected decision flips them red). No lens/std code touched.
The substrate dissolution (unify Map representation so structural-key == is decidable)
remains the tracked 🟡 in v4.std.collection; this PR does not undertake it and does not
wire these receipts into any CI gate roster (left to the lens-CI lane, per brief).
Tests: gunbc run --claim-run on all four witnesses + irt1_leaf_claim_suite → true;
perturb (rest:[proof]->[]) → false.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
briansrls
marked this pull request as ready for review
June 8, 2026 19:12
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Triages and fixes the runtime-false affected_set frontier receipts named in the work item (
excluded_propagation_proof,irt1_excluded_propagation_receipt) plus the two same-root-causedimension_seedreceipts that block the IRT-1 leaf suite.Triage verdict: it is the BROADER map-equality substrate, NOT local
mark_excluded/mark_rerun.ReExecFrontier.decisionsis a stdMap<K,V>, which is a PartialFunction (v4.std.collection:lookup: fn(K) -> Witness<V>). Over structural (non-String) keys (ExclusionKey), the v2 runtime drops out of the nativeValue::Map(HashMap<String,Value>) fast path — themap_insertbuiltin only matchesValue::Strkeys — and lands on the closure/record formMap { lookup: fn... }.PartialEq for Valuehas no closure arm, so two such maps compare_ => false, even a value against itself.Probe receipts:
empty_map()==empty_map()true; one structural-key entry== itselffalse;expected_frontier == itselffalse; key/proof/Nodevalue equality all true (so values are fine — only the Map==is broken). Somark_excluded/mark_rerunproduce the correct structure; the receipts asserted an undecidable whole-frontier==.Fix (model-correct, test-only)
A PartialFunction is observed by application. New shared helper
frontier_observation.frontier_decision_matcheslooks the seeded key up viamap_getand compares the resolvedFrontierDecision(a coproduct over lists/records, which do compare structurally). No lens/std code touched — onlysrc/v4/test/claim/lens_affected_set/. Not wired into any CI gate roster (left to the lens-CI lane).Perturb-discrimination evidence (committed, reviewable)
Each receipt ships a committed
_discriminateswitness proving the comparison is a real structural compare, not a tautology that launders brokenMap==into a weaker always-true:*_excluded_*_discriminates: a singlemark_excludedyieldsrest:[], which must NOT match the accumulated expected decisionrest:[proof]→ assertsfrontier_decision_matches(...) == false.*_dimension_seed_*_discriminates: the seeded decision isRerun, which must NOT match a wrongExcludeddecision → assertsfrontier_decision_matches(...) == false.If
frontier_decision_matcheswere a tautology, these would all be false. They are all true, i.e. the wrong expected decision is correctly rejected (perturb-red).Test plan
target/release/gunbc run --source-root src/v4 --entry <file> --function <fn> --claim-run:excluded_propagation_proof_claim_holdsexcluded_propagation_proof_discriminatesirt1_excluded_propagation_receipt_claim_holdsirt1_excluded_propagation_receipt_discriminatesdimension_seed_rerun_claim_holdsdimension_seed_rerun_discriminatesirt1_dimension_seed_receipt_claim_holdsirt1_dimension_seed_receipt_discriminatesaffected_set_irt1_leaf_claim_suite_holdsThe real structural-key
Map==substrate fix (unify Map representation) stays the tracked 🟡 inv4.std.collection— a separate load-bearing std.collection lane, not this PR.Closes #N (dashboard node adhoc-29b13bdc-60a)