You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
add a bounded COMMUTATIVITY_WITNESS_PAIRS sample table alongside associativity witnesses
wire AlgebraicLaw(Commutativity, lens_ref) through the runner using the existing predicate surface and a shared structural-value comparator
keep Identity fail-closed with the missing identity-element edge called out, and keep distributivity routed to the P1 substrate enum-extension path
add focused runner tests for commutativity pass/fail and the identity blocker
Verification
cargo fmt --all --check
git diff --check
Attempted focused test: cargo test -p v3-compiler test_runner_algebraic_law_commutativity --test integration.
With the default target dir it failed with No space left on device while writing dependency files on the /Users worktree volume.
Retried with CARGO_TARGET_DIR=/tmp/gunbc-pr-b3-target; dependency compilation proceeded but remained in v2-compiler compilation for about 30 minutes, so I stopped it rather than leave a runaway job.
src/v3/compiler/tests/integration/test_runner_test.rs:1018-1021 (and similarly 1051-1054): New tests assert on human-readable ClaimResult strings via .contains(...). TESTING.md (“Anti-patterns” → don’t pin error message text) treats that as a brittle contract; for the subtraction case, matches!(..., ClaimResult::Fail(_)) (or a typed/stable carrier if one exists) would assert the behavior without coupling to wording.
Verdict
APPROVE_WITH_COMMENTS — The runner change mirrors the existing associativity pattern: bounded witness table in lens_apply.rs, compile-time len() > 1 ratchet, explicit “operational witness, not substrate proof” + dissolution language in test_runner.rs, and Identity stays fail-closed / NYI with a clear rationale. Nothing here looks like substrate duplication of authority beyond the already-documented runner scaffold. The only rubric-aligned nit is the new substring-based test assertions above.
Exploratory (optional)
src/v3/compiler/src/test_runner.rs:305: The unreachable! after string matching is conventional for “validated twice” flow; if you ever want to avoid panic surfaces in this helper entirely, the inner match could return the same UnsupportedLaw/MalformedPayload path instead (implementation taste, not a modeling violation).
Follow-up PR opened for the review nit about substring-based assertions: #1363
It replaces the message substring checks with typed ClaimResult::Fail(_) / ClaimResult::NotYetImplemented(_) matches. git diff --check and cargo fmt --all --check passed; focused test still stalls in dependency compilation in this environment, matching the original PR note.
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
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
Verification
Attempted focused test: cargo test -p v3-compiler test_runner_algebraic_law_commutativity --test integration.