Skip to content

feat(verdict-corpus): Perl verdict corpus with fact packets, and Perl findings on the changed line - #6612

Merged
EffortlessSteven merged 16 commits into
mainfrom
claude/project-thread-y214zg
Oct 13, 2026
Merged

EffortlessSteven merged 16 commits into
mainfrom
claude/project-thread-y214zg

Conversation

@EffortlessSteven

@EffortlessSteven EffortlessSteven commented Oct 4, 2026 •

Copy link
Copy Markdown
Member

Requested by Steven · project thread

Summary

Before: ripr's Perl verdicts had no labeled corpus, so a change to a Perl oracle or reach rule could not show whether it made a verdict wrong. Perl findings also sat on the owner's sub line rather than the changed line.

After: fixtures/perl-verdict-corpus holds 36 runtime-labeled Perl cases across Test::More, Test2::V0 and Test::Exception. The required verdict-corpus check-all gate scores them with the Rust and TypeScript corpora, and the Perl rates are on the trust scoreboard. A Perl finding lands on the changed line when the diff confirms it.

  • Location fix (refactor(perl): project v2 facts into common RIPR evidence without lossy private mappings #3221). The producer writes zero-based change coordinates; the spec says one-based. change_lines_from_diff takes whichever reading is the only added line in the diff, and every settled change in a packet must agree on that basis. Otherwise the finding stays on the owner (fail closed). The probe id is unchanged, and main's perl: human output hides every Perl finding because source_currentness is always unresolved_subject #6586 currentness rule is unchanged.
  • Harness (on main's per-case layout, RIPR-SPEC-0245). The corpus header gains fact_producer (a pinned perl-ripr-facts commit). Each case gains perl_facts: the packet, its sha256, a producer or edited_producer provenance, and the edits. Packet cases run on the lang-perl build with --perl-facts. If a concurrent default build replaces the binary before the Perl copy, packet cases fail with a named error and are never scored as silent. Packet cases also count unresolved_subject findings: ripr keeps zero-based producer findings unresolved. Rows carry packet_provenance, and the derived summary reports by_packet_provenance. Rust and TypeScript rows are byte-identical.
  • Corpus. Three authored subjects (authored-perl-testmore-shop, -test2-ledger, -testexception-account), 36 cases. Truth comes from hand-written mutants under prove -l t, each with its mutated_line, because no Perl mutation tool drives all three libraries. 27 cases use the producer packet as written. The other 9 edit a producer packet to reach RIPR-SPEC-0235 examples 1, 12, 13, 14, 19, 23, 24, 25 and 28; their rates are reported separately.

Results, producer packets only: 5/15 false actionable, 3/12 false exposed, 0/12 false silent, 8/27 abstained. All verdicts are unchanged by the merge of main. Eight exposed_without_discriminator contradictions are gone after #6584. Gaps filed: #6581, #6582, #6583, #6584 (fixed on main), #6586 (fixed on main), #6619. Evidence was also added to #5421.

Swarm / Source Boundary

  • ordinary feature, analyzer, editor, docs, spec, fixture, badge, dependency, or repo-ops development for ripr-swarm

Source-of-truth Links

Proposal: none
Spec: RIPR-SPEC-0245 (Perl corpus section added), RIPR-SPEC-0235 (examples as cases)
ADR: none
Plan item: verdict-corpus coverage per language
Governing issue or accepted claim: #3221 (location); Steven's "effectively full corpus coverage" ask
Acceptance delta (one sentence): Perl verdicts are scored against runtime mutant truth with a regression gate.

Candidate Relationships

Candidate branch: claude/project-thread-y214zg
Stack parent or prerequisite PR (if any): none; the TypeScript harness landed on main (#6686) and this branch merges it.
Proposed replacement of PR (if any; not yet accepted): none

Scope Classification

  • One production behavior
  • Docs/spec/test-only evidence package

Production delta:

  • crates/ripr/src/analysis/language/perl/mod.rs: the probe location comes from the diff-confirmed changed line.

Evidence/support delta:

  • The Perl corpus, the harness extension, 5 trust metrics (producer rates).

Single acceptance criterion:

  • cargo xtask verdict-corpus check-all passes and fails on any Perl verdict change.

Non-goals:

Support-tier Impact

  • none

Claim/proof notes:

  • Rates describe this authored corpus only. Edited-packet rates are not producer evidence.

Proof

cargo xtask verdict-corpus check-all                     # perl 36 (13/36), rust 350, typescript 101; exit 0
cargo test -p xtask --bin xtask verdict_corpus           # 100 passed
cargo test -p xtask --bin xtask dx_scoreboard            # 87 passed (13 corpus-row sources)
cargo test -p ripr --features lang-perl --lib analysis::language::perl   # 118 passed
cargo xtask precommit                                    # exit 0 on 86a94eb

The required check runs on the CI head.

Claim Boundary

May claim: the corpus measures ripr's Perl verdicts on these 36 cases, and every rate is recorded. Must not claim population rates, or that ripr's Perl support is accurate: the producer rates show real false exposed and false actionable verdicts.

Rollback

Revert the squash commit.

Spec-Test-Code Traceability

  • Spec: RIPR-SPEC-0245
  • Tests: xtask/src/reports/verdict_corpus_tests.rs (7 Perl tests), perl/tests.rs (3 location tests)
  • Code: xtask/src/reports/verdict_corpus.rs, xtask/src/reports/fixtures.rs, crates/ripr/src/analysis/language/perl/mod.rs
  • Golden outputs: fixtures/perl-verdict-corpus/expected/rows
  • Metrics: trust.perl_verdict_corpus_*

Static Language Check

  • Static output avoids killed, survived, untested, proven, and adequate.

Engineering Check

  • No new panic, unwrap, expect, todo, or unimplemented in production code.
  • New non-Rust programming files: Perl sources live under fixtures/**, already allowlisted.

Gates

  • cargo fmt --check
  • cargo xtask precommit

🤖 Generated with Claude Code

https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7

claude added 7 commits October 4, 2026 23:03
`cargo xtask verdict-corpus validate|check|report` take
`--language <rust|typescript|python|perl>` and read
`fixtures/<language>-verdict-corpus`. corpus.json gains a `language`
(absent = rust); a directory declaring another language is refused. Rust
keeps its run and report paths and its report bytes; other languages nest
under <language>/ and name their language in both report files.

Separate directories keep TypeScript, Python and Perl label changes from
re-blessing the Rust expected report (RIPR-SPEC-0233).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UJ4NsYR4vJfn1cC6yRC1N5
…0238

RIPR-SPEC-0233 is taken by the Python oracle rules spec.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UJ4NsYR4vJfn1cC6yRC1N5
A Perl finding sat on the owner's declaration line read as one-based,
which with the real producer's zero-based coordinates is the line above
`sub name {`. ripr now takes the change's line when exactly one reading
(zero-based or one-based) is a line the diff adds, and otherwise keeps
the old location. Probe and canonical gap identity do not change.

Also drops two clone-on-copy calls that failed lang-perl clippy.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
36 runtime-labeled cases across Test::More, Test2::V0 and Test::Exception,
each with the packet the pinned perl-ripr-facts producer wrote. Cases built
from RIPR-SPEC-0235 packet shapes are marked edited_producer and reported
apart. The harness passes each packet with --perl-facts to the lang-perl
build and counts unresolved_subject Perl findings (#3280). Perl rates join
the trust scoreboard.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
…-y214zg

# Conflicts:
#	crates/ripr/src/analysis/language/perl/tests.rs
…subjects

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@EffortlessSteven EffortlessSteven self-assigned this Oct 4, 2026
@coderabbitai

coderabbitai Bot commented Oct 4, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Important

Review skipped

We couldn't safely recover the incremental review. No full review was started, and the last reviewed checkpoint was preserved. Retry later, or explicitly request a full review by commenting @coderabbitai full review.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 4627ae55-e84f-42b1-8b61-a5df0a2fc76a
📥 Commits

Reviewing files that changed from the base of the PR and between 4fd703f and 02e6c82.

📒 Files selected for processing (1)
  • changelog.d/perl-verdict-corpus.md
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 0 remain after this review.

Summary by CodeRabbit

  • New Features
    • Verdict-corpus commands support selecting Rust, TypeScript, Python, or Perl, with Rust as the default. Each language can use its own fixtures, reports, and regression checks.
    • Added a Perl verdict corpus covering labeled cases from several Perl testing frameworks, with verdict and abstention rates included in the trust scoreboard.
  • Bug Fixes
    • Perl findings are placed on a changed line when the diff identifies one unambiguous match; otherwise, they remain at the owner declaration.

Walkthrough

The pull request adds language selection to the verdict-corpus harness, supplies a Perl corpus with pinned fact packets and expected reports, and updates Perl analysis to locate findings on uniquely matched changed lines.

Changes

Per-language verdict corpus

Layer / File(s) Summary
Language selection and corpus harness
docs/specs/RIPR-SPEC-0238-per-language-verdict-corpora.md, xtask/src/command.rs, xtask/src/reports/fixtures.rs, xtask/src/reports/verdict_corpus.rs, xtask/src/reports/verdict_corpus_tests.rs, docs/specs/README.md, policy/doc-artifacts.toml, .ripr/traceability.toml
The harness accepts --language for validation, checking, and reporting. Rust remains the default. Non-Rust corpora use language-specific paths and report labels. Perl cases require pinned fact packets and producer metadata; reports include packet provenance rates. Tests cover language selection, validation, scoring, and reporting.
Perl corpus cases and evidence
fixtures/perl-verdict-corpus/*, benchmarks/dx_scoreboard/scoreboards.toml, changelog.d/perl-verdict-corpus.md, .gitattributes
Adds labeled Perl cases, subject projects, fact packets, and expected JSON and Markdown reports. The corpus covers Test::More, Test2::V0, and Test::Exception cases. Five Perl verdict and abstention metrics are registered on the scoreboard.
Perl finding-line mapping
crates/ripr/src/analysis/language/perl/mod.rs, crates/ripr/src/analysis/language/perl/tests.rs, crates/ripr/src/analysis/language/perl/static_limit/runner_tests.rs, changelog.d/perl-finding-on-changed-line.md
Perl analysis uses diff-added lines to resolve packet change locations. It selects a line only when one candidate interpretation matches, and otherwise retains the owner-declaration location. Tests cover successful and fail-closed mapping cases.

Priority: ➖ Normal

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant CLI
  participant CorpusHarness
  participant PerlBinary
  participant Ripr
  participant Report
  CLI->>CorpusHarness: select language and load corpus
  CorpusHarness->>PerlBinary: resolve Perl fixture binary
  CorpusHarness->>Ripr: run case with pinned fact packet
  Ripr-->>CorpusHarness: return findings
  CorpusHarness->>Report: score cases and write report
Loading

Merge Risk: ⚪ Minimal · up to 02e6c

The changelog matches the documented Perl corpus and check behavior. No material merge-blocking risk is evident.

Architecture Summary

Architecture risk: 🔵 Low · up to 02e6c

The change affects 7 systems.

Changed systems: fixtures, xtask, changelog.d, crates, docs, benchmarks, policy

Architecture concerns
No architecture-level concerns identified.

Review details

Systems and components

  • observed — fixtures (service) was modified; 87 changed files map to changed impact.
  • observed — xtask (service) was modified; 4 changed files map to changed impact.
  • observed — changelog.d (service) was modified; 3 changed files map to changed impact.
  • observed — crates (service) was modified; 3 changed files map to changed impact.

Before / after behavior

  • observed — Modified behavior in changelog.d/perl-finding-on-changed-line.md: Added a changelog entry documenting Perl preview finding-line selection and the stated unchanged probe and gap identity.
  • observed — Modified behavior in changelog.d/spec-0238-per-language-verdict-corpora.md: Adds a changelog entry documenting the language-specific verdict corpus commands and fixtures, the Rust default for corpora without language, and byte-preserving Rust reports.
  • observed — Modified behavior in crates/ripr/src/analysis/language/perl/static_limit/runner_tests.rs: boundary assigns change.range directly instead of cloning it.
  • observed — Modified behavior in crates/ripr/src/analysis/language/perl/static_limit/runner_tests.rs: perl_static_limit_missing_runner_respects_scope assigns test.range directly to test_boundary.range instead of cloning it.
Pre-merge checks · Passed 4 · Failed 1

Failed Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 61.02% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 59 functions across 7 files. (1 skipped: … Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks (4 passed)
Check name Status Explanation
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Title check Passed The title clearly identifies both primary changes: the Perl verdict corpus with fact packets and changed-line finding locations.
Description check Passed The description is mostly complete and directly covers the change, scope, evidence, proof commands, claim boundary, rollback, traceability, and selected checks. It omits the template's Scope section a…
Full details: Docstring Coverage

Explanation

Docstring coverage is 61.02% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 59 functions across 7 files. (1 skipped: 1 unsupported.)

✨ Finishing Touches 💡 1
⚔️ Resolve merge conflicts 💡
  • Resolve merge conflict in branch claude/project-thread-y214zg
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

A rabbit checks each labeled case
And pins the facts in their place
A changed line earns a marker
When one match makes it clearer
Rust and Perl reports take shape
While test notes fill the page

Comment @coderabbitai help to get the list of available commands.

coderabbitai[bot]

This comment was marked as resolved.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reporter summary

Every specialist lane failed preflight and produced no evidence, and the late cargo-test sensor timed out after 900s without a receipt, so this review has zero substantive lane conclusions to weigh. The PR itself is large but well-scoped (a Perl verdict corpus plus a single behavior change to the Perl adapter's change-line location, with tests, spec, traceability, and changelog fragments) and claims byte-identical Rust report bytes plus authored Perl subjects; without a working lane or cargo-test receipt, I cannot confirm those claims or check for risks beyond what the diff itself states.

- Perl change lines need one coordinate basis across the packet, and an
  overflowing start line is skipped instead of panicking.
- The lang-perl fixture binary gets its own name, so a process that builds
  both feature sets never runs the wrong one.
- Relabel three cases whose rewrite was not exactly behavior-preserving
  (freeze-class defined vs truthy; two float rewrites), and correct two
  reasoning values.
- Perl scoreboard metrics read producer-packet rates only, and the spec and
  changelog say no CI lane runs verdict-corpus check yet.
- fact_producer.commit must be lowercase hex.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7

Copy link
Copy Markdown
Member Author

Fragment preparation for #6800, inspected current head 4fd703f871b4d0aa5d0e04d5259bee0c08cd62e0. Existing branch/session remains the writer.

Source inspection found: perl-verdict-corpus.md: reference missing; spec-0238-per-language-verdict-corpora.md: reference missing. Please repair those entries with the section matching their intent and a true governing issue or introducing PR reference, preserving their prose. This is source preparation, not an actual-checker failure receipt or a request to change Ready/Draft state. Repair current main and affected heads before strict enforcement; then evaluate fresh main+gate composition with the verified immutable checker, independent exact-head review and required checks.

The shared spec-0238-per-language-verdict-corpora.md is identical across #6686/#6798/#6612/#6597: coordinate one producer repair through the existing #6686 TypeScript harness writer, then reuse it in dependent heads.

Return the exact repaired head and source diff here. Actual-checker execution remains pending executable custody as specified in #6800; no new Cargo build or installation is authorized in this source-only lane.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7

Copy link
Copy Markdown
Member Author

Status for the night, at head 02e6c82: this is a status note, not a review of record, and the PR stays Draft and unmerged.

Fragment repair (#6800). changelog.d/perl-verdict-corpus.md now names its introducing PR (#6612). Source diff: (RIPR-SPEC-0238) became (RIPR-SPEC-0238, #6612); the prose is unchanged. spec-0238-per-language-verdict-corpora.md is unchanged here, because it belongs to the harness writer on #6686. This PR will take that writer's repair when it merges main. No Cargo build was run for this change.

Done on this PR

  • Three independent reviews of 48bf714 found nothing blocking: code correctness, all 80 mutant labels re-run under prove, and spec/gate honesty.
  • 4fd703f fixed their findings and CodeRabbit's four:
    • one coordinate basis across the packet, with checked_add;
    • a separate ripr-lang-perl binary;
    • three cases relabeled so the rewrites preserve behavior exactly;
    • two reasoning values corrected;
    • Perl scoreboard metrics read producer-packet rates only;
    • the docs say no CI lane runs verdict-corpus check yet.
  • CodeRabbit's re-review of 4fd703f found nothing actionable, and all threads are resolved. Third-party checks were green on 4fd703f.

Left open

Follow-up issues: #6581, #6582, #6583, #6584, #6586, #6619.


Generated by Claude Code

@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 3 potential issues.

Devin Review

Comment thread xtask/src/reports/fixtures.rs Resolved
Comment thread xtask/src/reports/verdict_corpus.rs Resolved
Comment thread xtask/src/reports/verdict_corpus.rs Resolved
Main moved the verdict corpus to one file per case and row, renumbered the
per-language corpora spec to RIPR-SPEC-0245 (0238 is now Python's oracle
rules), and added check-all. This port:

- moves the Perl packet validation, --perl-facts run, lang-perl build and
  packet-provenance rates onto main's harness; provenance now lives on each
  row and the summary derives it;
- splits the Perl corpus into per-case files, adds each rewrite mutant's
  mutated_line, and re-blesses its rows (verdicts unchanged; eight stale
  exposed_without_discriminator contradictions are gone after #6584);
- keeps main's #6586 currentness rule and only places Perl findings on the
  diff-settled changed line;
- moves the Perl corpus section into RIPR-SPEC-0245 and points the Perl
  scoreboard metrics at the derived producer rates.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
Both builds write target/debug/ripr. The Perl build now holds an exclusive
lock beside that binary across its build, its copy to ripr-lang-perl and a
default rebuild, and the default build takes the same lock, so neither a
thread nor another xtask process can swap the binary between the Perl
build and its copy (Devin review on #6612).

Also states the current reason Perl findings stay unresolved_subject in
the corpus projection (#6586, #3221), and tightens two Perl tests: the
producer-case helper no longer falls back to an edited case, and each
provenance bucket's case count is pinned.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
@EffortlessSteven
EffortlessSteven marked this pull request as draft October 12, 2026 19:52
@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 12, 2026 19:52
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed findings

  • RIPR-SPEC-0238 is referenced from RIPR-SPEC-0245 but the spec-0238 file fragment is owned by a sibling PR (per seeded thread: shared file is identical across #6686/#6798/#6612/#6597). When this PR merges first it inherits a doc fragment it does not author. Not a blocker; spec-0238 owner should land the same repair via #6686 or the doc lands with a brief mismatched cross-reference until then.
  • xtask/src/reports/verdict_corpus.rs:1199 — is_perl_corpus uses dir.file_name().and_then(name.to_str).strip_suffix with a borrowed slice; if the corpus dir is symlinked or its file_name differs from the canonical lowercase, the test mistakenly treats it as non-Perl and skips producer/packet validation. The architectural fix is to key off the corpus.json schema header (e.g. a declared language field) rather than the directory name.
  • with_fixture_build_lock opens target/debug/.ripr-fixture-build.lock with OpenOptions::create(true).truncate(false).write(true) on each build; on Windows over SMB or on slow NFS this lockfile may remain after a process crash and serialise future fixture builds. Not security, no CVE.
  • assertion seen == 13 plus per-metric ratio = rate.split('.') lookup covers only the new Perl metrics in lockstep; if a future language adds another dotted path the same call will silently fold into one of the existing branches. Pin the per-language expected count set and add a language↔metric manifest comment so a future contributor cannot regress the gate by adding a metric without updating the count. (xtask/src/reports/dx_scoreboard/tests.rs:2577).
  • ub-active-view is a JS/WASM/buffer lane; this PR is a Perl verdict corpus and Rust analyzer/harness change. The lane's subject matter does not intersect the diff, so this is a no-finding lane.

Verification questions

  • Confirm by_packet_provenance aggregation reuses existing OriginRates via origin_rates(&subset) keyed on PacketProvenance::as_str(); subset filter is r.packet_provenance == Some(provenance), and rows carry packet_provenance as Option. Sum invariant proven in test (producer.cases_total + edited.cases_total == corpus.cases.len()).

Refuted

  • Perl change_id pairing logic could index past current packet length under a stale buffer snapshot.; refuted because: Pairing iterates packet.changes and diff_file.added_lines; both are owned Vecs under the same scope, no external view retains an earlier length. Change-id lookups are bounds-checked by BTreeMap::get, not by raw indexing.
  • with_fixture_build_lock could deadlock by re-entering the same lock from the inner run_corpus fan-out.; refuted because: fs::File::lock is advisory and held on the file fd; the lock is acquired once in with_fixture_build_lock and released when lock drops at function return. No re-entry path exists because the inner call is the leaf.
  • Origin-controlled packet path could traverse out of dir via canonicalize() or ..; refuted because: Validator's perl_facts_violations rejects paths not under packets/ and unsafe paths; only after that gate does run_case call path::absolute. No escape.

Evidence gaps

  • Model proof intent was rejected by deterministic validation.

Parked follow-ups

  • report_keeps_edited_packet_rates_apart_from_producer_rates checks provenance-split numerator sums against the top-level totals; if a corpus ever grows a third PacketProvenance variant the per-provenance counts will silently leave rows out of any bucket, and + edited.numerator == top.numerator will fail opaquely. A match over all PacketProvenance variants in the sums assertion (or an is_subset debug assert) is enough; flagging as a parked follow-up, not a blocker.
  • Devin's producer-authenticity concern (sha256 pins bytes, not authorship) is already parked under #3221; regenerating packets after the coordinate basis is fixed is the agreed plan. No new sibling risk found.

…cking builds

The build lock from 833ec21 made fixture-cache children wait on it
instead of on Cargo's own artifact lock, which three contention tests
require (Rust gates on 833ec21). Drop the lock. The Perl build still
copies to ripr-lang-perl and restores the default build. If another
process's default build lands before the copy, every packet case now
fails with a named error (its Perl language run is `unavailable`)
instead of scoring as silent.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
@EffortlessSteven
EffortlessSteven marked this pull request as draft October 12, 2026 20:52
@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 12, 2026 20:52
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

# Conflicts:
#	.ripr/traceability.toml
#	docs/specs/RIPR-SPEC-0245-per-language-verdict-corpora.md
#	xtask/src/reports/dx_scoreboard/tests.rs

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision

  • Needs reviewer attention before upstream: findings remain.

Confirmed findings

  • The new ripr_perl_fixture_binary copies target/debug/ripr to target/debug/ripr-lang-perl without a Cargo lock. A concurrent cargo build (or repo-test harness without the same hash lock) can race the copy. Worst case: refuse_unavailable_perl errors every packet case with a named error, never a silent verdict. No secrets, no RCE.
  • all 36 expected rows agree with the corpus labels and the rebuild-from-rows test passes; the 13/36 producer-passing claim is only verifiable by the broker via cargo xtask verdict-corpus check --language perl, not by inspection.

Verification questions

  • Confirm validator_holds_perl_packets_to_their_pins_and_provenance covers eight tamper shapes (no facts, bad sha, path outside packets/, edited without edits, producer with edits, no producer, short commit, uppercase commit). It does NOT cover: an edit packet whose sha256 matches a hand-built packet on disk, or a packet edited into a path containing '..'.
  • Confirm the rust corpus has its own expected rows; only the Perl corpus adds the packet_provenance field. If a future language adapter grows its own packet-shaped corpus, the row field stays Option and render_report_json omits when None, so no silent regression. The field is also present in expected/rows for Perl only; no sibling corpus to confuse today.

Parked follow-ups

  • RIPR-SPEC-0238 fragment is cross-PR shared and the seed says this PR will land with the wrong cross-reference until #6686 writes it.

Evidence gaps

  • Model proof intent was rejected by deterministic validation.

Keeps both the Perl and Python entries in traceability and RIPR-SPEC-0245.
The scoreboard test now counts 16 corpus-row rates.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
Keeps this branch's resolution; the tree is unchanged.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7

Copy link
Copy Markdown
Member Author

Status on 614d161 (Perl thread winding down for the night):

Next step, for whoever picks this up: once #7547 merges, merge main into this branch, check that no routed-rust run is in flight, then toggle Draft→Ready. Post the review of record and merge when green. I left the PR Ready, but the required check has not run on this head.


Generated by Claude Code

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision

  • Needs reviewer attention before upstream: findings remain.

Confirmed findings

  • packet_to_findings_with_currentness threads &BTreeMap<change_id,line> through the call; the map outlives change_lines_from_diff but is consumed (collected into the probe loop) before the function returns, and the diff &ChangedFile slice is borrowed for the call duration. No self-referential aliasing. Reported for completeness; not a public issue.
  • xtask/src/reports/fixtures.rs:847 — ripr_perl_fixture_binary copies target/debug/ripr to target/debug/ripr-lang-perl with no size guard; a zero-byte file from a failed cargo build would later be invoked as the Perl binary and only the corpus refusal saves the run. Consider copying only after run() returns Ok, then re-checking fs::metadata(&perl).len() > 0 before returning.
  • run_corpus prebuilds both fixtures only if the corpus carries any packet case (perl_facts.is_some) or non-packet case; a corpus that mixes packets with non-packets still triggers both builds even when the only packet cases would not run in this process. This costs one extra lang-perl build on any future mixed-language corpus, which is harmless today because no such corpus exists.

Verification questions

  • Confirm is_perl_corpus keys off dir.file_name() == "perl", so a symlinked corpus dir misclassifies; matches the seeded Devin observation and is keyed to a directory path, not file content.
  • Confirm edited-packet provenance is a per-case opt-in via 'edits' text. A reviewer can confirm a packet's sha matches the producer's bytes, but cannot confirm a 'producer' packet is actually the producer's output without reading the producer's commit and re-running it. This is documented (RIPR-SPEC-0245 'producer receipt belongs with #3221') and the claim boundary explicitly excludes 'producer-authorship checked'.

Parked follow-ups

  • No comparable guard exists for callers of ripr_fixture_binary outside run_corpus. Other xtask/test surfaces that exercise ripr today (xtask/src/reports/fixtures.rs callers, precommit, miri, mutants harnesses via with_fixture_build_lock) write to target/debug/ripr. The new lang-perl build also writes to that path then copies. If any other xtask surface invokes ripr_fixture_binary concurrently with a Perl-corpus run on the same machine, it could overwrite ripr-lang-perl before/after the copy. The seeded review-comment explicitly noted this race; 86a94eb chose 'fail closed on unavail' as the safety net rather than serializing.
  • Refuse-unavailable covers the wrong-binary case at run time (a Perl case whose binary lacks lang-perl is a named error, not a silent verdict). The build-race sibling path is parked per the seeded thread; this lane has no additional blocker. Helper documentation in fixtures.rs:818-828 already names the ordering caveat and points at run_case/refuse_unavailable_perl as the safety net.

Evidence gaps

  • Model proof intent was rejected by deterministic validation.
  • Late cargo-test receipt was absent at packet time; cannot confirm runtime byte-identity of Rust report rows.

…corpus branch

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011spuQeUHZ5cHS2Hix5zZd7
@EffortlessSteven
EffortlessSteven marked this pull request as draft October 12, 2026 23:12
@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 12, 2026 23:12
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Decision

  • Needs reviewer attention before upstream: findings remain.

Confirmed findings

  • Basis disagreement between cases produces an empty BTreeMap by design (the bases.len() > 1 guard). Findings then keep the owner's start_line and start_column, so location ownership remains the owner's range — a Copy value. No memory hazard, but worth noting the guard in an audit so a future maintainer does not 'fix' it by retaining the partial map.
  • fact_producer.credential.exposure: the command lives in repo JSON, and corpus validation only checks that every field is non-empty and commit is a 40-char lowercase sha. A Perl corpus can therefore pin a producer command that includes tokens the publisher never intended to expose; a reviewer reading fact_producer.command for an expected shape does not see what runs at production call sites.

Refuted

  • box-from-slice / Box::from(slice) allocation failure on the digest path could silently produce a zero-length sha256 and pass the pin check; refuted because: sha256_hex is implemented via the sha2 crate producing a 32-byte fixed array into a Vec; allocation failure returns Err, never a zero-length box. validator surfaces that Err as 'is unreadable', not as a sha256 mismatch.
  • The Perl adapter reads packet bytes back as a string with packet_text and could leak to JSON, including the sha256 pin being broadcast in stderr if logging is verbose; refuted because: No secret material exists in the packet (test diffs, file content, oracle metadata); sha256 is committed alongside bytes; no credentials in scope. Adversary model is reviewer, not external attacker.
  • The 9 edited packets could be hand-built to match a sha256 on disk and bypass provenance; refuted because: Documented by Devin as PacketProvenance limits (sha256 pins bytes not authorship); validator_holds_perl_packets_to_their_pins_and_provenance tests eight tamper shapes but not path-traversal (../) or packet hash collisions; #3221 is the named issue; edits_cover and bare_cover tests cover the provenance field; sha256 mismatch is the documented check.

Parked follow-ups

  • Diff narrowed the probe line to one-based only when exactly that reading matches an added line, else falls back to owner fallback. checked-by-tests perl_finding_lines_need_one_basis_across_the_packet covers u32/MAX overflow and disagreement.
  • Line 416 claims probe.location is (line, 1, ...) only when settled; owner fallback path is unchanged. Cached spec diff lacked the SourceLocation::new(... 1) body so I could not double-check the column. parked pending a build that produces the binary.

Copy link
Copy Markdown
Member Author

Review of record — head 211290f

CI on this head: Ripr Rust Small Result passed (run 38320889698). All 34 check runs completed with none failing.

Combined tree: I merged 211290f with current main 57ce572 locally (clean merge).

Angles and findings

  1. Correctness of the main port and the Perl location fix: two independent reviewer agents, earlier in this PR. Nothing blocking.
  2. Tests and corpus data (rows vs labels, mutated_line, provenance buckets, rebuilt summary): reviewer agent. Nothing blocking.
  3. Fail-closed wrong-binary handling (833ec21..86a94eb): an independent reviewer agent on this head. No blocking findings.
  4. External bots:
    • Devin's build race: the race now fails closed (my reply is on its thread). Its outdated --language finding is resolved, and its provenance analysis is answered.
    • CodeRabbit: its earlier threads were fixed in 4fd703f; later runs hit the rate limit. Gemini is over quota.
    • github-actions reviews on this head: the race is a known fail-closed case. A zero-byte copy can't happen, because the copy runs only after run()? succeeds. .. packet paths are already refused by safe_relative. fact_producer.command is provenance text that xtask never executes.

Resolution: nothing blocking. Merging (squash).


Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants