Repository navigation
fix(mcp): weak finding naming its missing discriminator is repair-ready (#8717) - #9200
Conversation
… target (#8717) Gate 2 of RepairReadiness::from_finding no longer refuses a weakly_exposed finding for naming its missing discriminator; other classes keep the typed refusal, and the fix-site gate plus shared seam validator still decide. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019ZHDKLVQqArSZrUFKSkREo
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning Review limit reachedEnable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Next included review available in 45 minutes. View limit details
Comment |
…inator readiness (#8717) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019ZHDKLVQqArSZrUFKSkREo
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Generated by Claude Code |
There was a problem hiding this comment.
Decision
- Needs verification checks before upstream.
Verification questions
- Confirm
repair.rstest was renamed to scope it to a non-weak class (ReachableUnrevealed), and adds a clarifying comment, but no assertion inside the renamed test was strengthened; the weak-pass branch relies entirely on the newmcp::gapstests for behavior coverage. - Confirm real-stdio control wires MCP repair_packet_ready and prepare_repair.attempt.state to the actual ripr repair CLI verdict (cli_repair_refusal) per finding_id, so the fixture is a two-sided invariant, not a single-shot readiness assertion.
- Confirm
gate 3(related-test grip) is asserted unchanged with the inline claim that the fixture's related test is already strong/high; the change relocates the typed refusal but does not re-prove gate 3 ordering on a weakly exposed repair target. A negative case asserting weak+named with a weak-only related test still ends at gate 3 (fix_site_not_test_surface) would harden the spec's gate-order statement. - Confirm no sibling public-API path or route beyond RepairReadiness::from_finding was changed in this diff. The widened branch is local to finding-level gate 2; the disclaimed scope (gate 3 and shared seam validator) is genuinely conjoined and the doc/spec update confirms the fail-closed conjunction. No re-introduction of an over-claim observed at the source-route level.
Refuted
- Renaming the test in
mcp::repaircould let the old failure slip through because the suffix changed but the assertion is identical.; refuted because: Comparison is the same produce-named missing discriminator with the canonical gap dropped; class flipped to ReachableUnrevealed, which strengthens the guard (covers every non-weak case via the WeaklyExposed complement). Not a regression. - The change removes discriminator readiness protection broadly.; refuted because: It exempts only WeaklyExposed findings and retains the canonical-gap, fix-site, and downstream shared seam-validator gates.
Evidence gaps
- Model proof intent was rejected by deterministic validation.
- The claimed Rust test proof has not yet been independently confirmed in the supplied packet; cargo-test is scheduled late, while ripr failed with exit code 2.
There was a problem hiding this comment.
Decision
- Needs one verification check before upstream.
Verification questions
- Confirm gate 3 ordering is not explicitly regression-tested for the newly admitted weak+named discriminator shape.
Refuted
- The widened branch misclassifies a weak named-missing finding that lacks a canonical gap.; refuted because: Unit controls explicitly remove the canonical gap and require discriminator_not_populated_for_language; the implementation still requires a populated gap before proceeding.
- RepairReadiness::from_finding is the wrong place for a class-conditional gate 2; the seam-level validator should own it.; refuted because: The seam validator's role is 'is the seam actually startable,' not 'is the finding-level discriminator established.' Gate 2 is documented as finding-level; fix-site and seam gates already conjoin downstream. Moving the condition would invert the documented order and require re-proving the spec's gate-order statement.
- The new stdio test is only a single-sided readiness assertion.; refuted because: It invokes cli_repair_refusal by finding_id for every listed weak item, requires at least one admitted and one refused item, and checks readiness, attempt state, typed ineligibility, and fix site against that verdict.
Parked follow-ups
- Gate-3 behavior is preserved indirectly rather than asserted with a dedicated weak-only-related-test control.
Evidence gaps
- The always-on cargo-test proof is scheduled late and no result is yet present in the supplied packet.
- Model proof intent was rejected by deterministic validation.
- The review packet provides no completed cargo-test receipt and reports RIPR failure, so runtime proof status cannot be confirmed from supplied evidence.
Governing issue or accepted claim: #8717 (partial: gate 2 only; #8717 stays open for gate 3)
Acceptance delta (one sentence): MCP finding-level readiness gate 2 now treats a producer-named missing discriminator on a
weakly_exposedfinding as the repair target instead of refusing it, while the fix-site gate and the sharedripr repairseam validator remain the only deciders.What changed
RepairReadiness::from_finding(crates/ripr/src/mcp/gaps.rs): a named missing discriminator refuses asmissing_discriminatoronly on non-weak classes. A weak finding still needs a populated canonical gap (elsediscriminator_not_populated_for_language/static_limitation) and a fix site (fix_site_not_established/fix_site_not_test_surface).readiness.evaluation_basiswire string now states that a named missing discriminator is accepted only on a weakly exposed finding.Not implemented: gate 3
Accepting a weak related test as the fix site (the issue's gate-3 proposal) is NOT implemented here. Gate 3 still requires a strong, high-confidence directly-related test. On the issue's fixture the related test is already strong/high (
assert!(is_adult(30))), so gate 3 was not blocking and there was no reproduction to justify relaxing it. #8717 stays open for that part.Exposedis not refused at the finding level: #9105's shared seam verdict already refuses seamsripr repairrefuses, and B4/DISCOUNT/FEE exposed-class items the CLI admits stay ready.Reproduction (binary from main fbb78fd)
Fixture:
is_adult> 18->>= 18, weak testassert!(is_adult(30)). Both weak gapsrepair_packet_ready: false,missing_discriminator. After the fix thepredicate_boundaryitem is ready with anawaiting_editattempt and fix sitetests/adult.rs; the siblingreturn_valueitem stays refused (seam_gate_refused, the same refusalripr repairgives).Proof
mcp::gaps,mcp::repair): weak+named ready; every non-weak class, weak without gap, weak without fix site stay refused.weak_boundary_naming_its_discriminator_is_repair_ready_only_where_the_cli_admits: MCP ready exactly whereripr repairadmits; the refused item has a typed seam reason and no attempt.agentic_bench_mcpB4b updated: the unpinned boundary now binds a packet.cargo fmt --all --check,cargo test -p ripr --lib mcp::(176 pass),--test mcp_stdio(24 pass),--test agentic_bench_mcp(15 pass).cargo xtask precommitnot run.changelog.d/8717-mcp-weak-discriminator-readiness.mdupdated.🤖 Generated with Claude Code
https://claude.ai/code/session_019ZHDKLVQqArSZrUFKSkREo