Skip to content

fix(review): verifier no longer invalidates findings its own reason confirms - #560

Merged
dan-petty merged 1 commit into
release/v0.2.23from
fix/536-verifier-self-contradiction
Sep 24, 2026
Merged

dan-petty merged 1 commit into
release/v0.2.23from
fix/536-verifier-self-contradiction

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

Closes #536.

Problem

In the first sample validation (#505), all three unpinned :latest image findings were INVALIDATED, although the verifier's reason confirmed the defect:

reason: "Line 6 contains FROM alpine:latest, which uses the unpinned latest tag."
invalidated criteria matched: ["The FROM directive still uses 'latest' as the image tag."]

The model filed the finding's own verification criterion, or its fix ("a specific tag such as golang:1.22.3 and a checksum"), as the invalidation it matched. These were 3 of the run's 6 found-then-dropped injections.

Changes (verification.py)

_without_self_refutation runs before the status is decided:

  • A matched invalidation criterion is not a refutation if it restates the finding's verification criteria, title or fix: at least 60% of their words, and closer to them than to the finding's invalidation criteria.
  • A reason that states the claimed condition without negating it confirms the finding.
  • When the invalidation rests only on those, it is withdrawn, the INVALIDATED status included, and the finding stays unverified and reported.
  • A genuine refutation still invalidates, even beside a restatement.

Test plan

  • tests/test_review_verifier_self_refutation.py (8 tests):
    • the criterion restated, reworded, or given as the fix;
    • no criteria with a confirming reason;
    • genuine refutations (digest, test fixture, and one beside a restatement);
    • an untouched confirmation.
  • tests/test_review_regression_harness.py: the run's two misread verdicts in the golden set
  • tests/test_review_verification.py: its invalidation case now matches the finding's invalidation criterion rather than its own claim
  • uv run devops ci --force: all 13 gates pass

…onfirms

The first sample validation (#505) found all three unpinned :latest image findings
invalidated although the verifier's reason confirmed the defect: it filed the finding's
own verification criterion, or its fix, as the invalidation it matched.

A matched invalidation criterion that restates the finding's claim, title or fix, or a
reason that states the claimed condition without negating it, no longer invalidates.
The finding stays unverified and reported. Genuine refutations still invalidate, even
beside a restatement. The run's misread verdicts are regression cases in the #509
harness.

Closes #536
@dan-petty dan-petty added this to the v0.2.23 milestone Sep 24, 2026
@dan-petty dan-petty added type/bug Type bug: the code does not do what it must scope/review Multi-persona code review engine, verification, and findings priority/p1-high Priority P1: high-impact work for the next planned milestone labels Sep 24, 2026
@dan-petty
dan-petty merged commit bc2b920 into release/v0.2.23 Sep 24, 2026
7 checks passed
@dan-petty
dan-petty deleted the fix/536-verifier-self-contradiction branch September 24, 2026 23:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

priority/p1-high Priority P1: high-impact work for the next planned milestone scope/review Multi-persona code review engine, verification, and findings type/bug Type bug: the code does not do what it must

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant