gunk-dev/the-valley
the-valley:bd-25d0640bugopen

The integrator's evidence selection lets a verified failure note veto a later pass

State
free to start
Created
2026-10-22 by contributor

Body

From the review of rspx (Codex, 2026-10-22). `change.SelectNotes` (shared by the integrator and approve's coverage) keeps the first note that verifies for a check, even when it records a failure or is the wrong kind (change/evidence.go:48), and the integrator discards runner and attribute and accepts an unmoved pure pass without comparing them (integrator/evidence.go:100, integrator/verdict/verdict.go:393). Approve's coverage is deliberately stricter on attribute.

Not urgent: today `attest run` publishes nothing when a check fails (attest/run.go:153), so no published failure can block a pass yet. It matters once workers or anyone publish failures.

Fixed when selection takes the first currently authorized note that satisfies the required pure check exactly (name, runner, attribute, tree, passing result), keeps failures and wrong-kind notes as diagnostics, preserves the closure and derivation checks for moved trees, and keeps rejection diagnostics when no note qualifies. Contradictory results for a pure check are worth surfacing, not retrying until green (schema/attestation.cue's reproducibility promise).

Comments

  1. contributor2026-11-02 23:48 UTC
    Change ovrm (commit ebe02c91) fixes the runner and attribute part. The integrator keeps each note's signed predicate.check.runner and predicate.check.attribute (integrator/evidence.go), and weigh counts a note for a check only when both equal the policy's required runner and attribute (integrator/verdict/verdict.go). This holds on an unmoved tree, for a transferred note, and for the landing tree's own evidence. A mismatch is no evidence, and the reason names both computations. This is the test approve's coverage already applied (status/coverage.go). The selection part stays open: change.SelectNotes still keeps the first note that verifies, so a failing note can mask a passing one. With the attribute rule in place, a wrong-attribute note selected first now masks a correct note from a later signer the same way. valley-request case 20d hit this through key order, so it no longer publishes such a note.