Repository navigation
fix(calibrate): disclose truncated agreement tables in markdown - #7841
Conversation
The runtime-signals-without-static-gaps and static-gaps-without-runtime-signals markdown tables were silently capped at 50 rows. Render "Sample only; showing N of M" when truncated, keep JSON lists capped without new schema fields, and mirror the same markdown disclosure in xtask mutation-calibration. Co-authored-by: Steven Zimmerman, CPA <EffortlessSteven@users.noreply.github.com>
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
EffortlessSteven
left a comment
There was a problem hiding this comment.
review-pr (published head, author COMMENT)
GitHub cannot request changes from this author identity; COMMENT plus an explicit disposition is the review event, not approval.
reviewed_head_sha: a14afc5a8b1eb49efa3c5279632f01c3f2fc93cd
integration_basis: origin/main ff4a2fcd6 (PR GitHub base currently d40e2b4; behind-only, no restack)
claim_boundary: markdown-side sampling disclosure for truncated calibration agreement tables; no new JSON fields; #7760 surfaces untouched
changed_surfaces_and_semantic_owners_inspected:
- crates/ripr/src/output/mutation_calibration.rs (product markdown renderer + report totals)
- xtask/src/reports/mutation.rs (duplicate xtask markdown renderer)
- unit tests in mutation_calibration.rs and xtask/src/tests.rs (heading strings preserved)
- changelog.d/7744-calibration-agreement-sample.md
- JSON renderer left without new keys; existing calibration goldens under the 50-row cap
blocking_findings: none from source/oracle inspection of this head
non_blocking_suggestions:
- product and xtask still duplicate the full calibration renderer; unifying them is out of this claim
refuted_or_stale_findings: none yet (no review threads)
proof_and_ci_observed:
- local red/green: agreement_tables_disclose_sampling_when_truncated failed 0 vs 2 sample notes, then passed
- cargo test -p ripr --lib mutation_calibration::tests (33 passed)
- cargo test -p xtask mutation_calibration (12 passed, headings still present)
- cargo test -p ripr --test cli_smoke calibration (5 passed; goldens unchanged)
- cargo xtask precommit pass; check-fast 11 gates / 6 files
- cargo xtask goldens check fails on owner_return_pin_fallible_literal on clean origin/main as well; not this delta
proof_or_review_missing:
- hosted required merge-gate jobs not yet terminal on this published head
- several draft-time check runs already skipped (msrv, rust-tests-junit, vscode, droid, …); Ready is needed for qualification
- external reviewer output not yet a current-head semantic pass
affected_currentness_dimensions: production implementation, test stimulus, test oracle, public markdown claim, candidate head identity
residual_assumptions_and_non_claims:
- JSON lists remain a 50-row sample; markdown now names the pre-truncation count when truncated
- does not prove runtime mutation results or that markdown is complete above 50 rows
- does not unify the xtask/product renderers
disposition: REVIEW_INCOMPLETE
Oracle challenge: removing push_agreement_sample_note or forgetting to capture totals before truncate still leaves 50-row tables and fails the 51-row unit test. Under-limit fixtures fail if the note is always emitted. JSON grows a total field only if the schema fence is broken, which the JSON assertions reject.
No merge until this exact head has terminal required checks and a follow-up REVIEW_READY.
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
Summary by CodeRabbit
WalkthroughBoth calibration report implementations now retain full counts for missed runtime signals and static-only findings while capping stored lists at 50 entries. Markdown reports disclose sampled tables; JSON continues to contain capped lists without added total fields. ChangesCalibration agreement reporting
Priority: ➖ Normal Estimated code review effort: 2 (Simple) | ~10 minutes Change: Bug fix · Severity of issue fixed: Medium Merge Risk: ⚪ Minimal · up to
|
There was a problem hiding this comment.
Confirmed findings
- Pre-truncation total is sampled once immediately after the callee returns and stored in the report; no second view of the same buffer can drift relative to it. The dual renderer (ripr + xtask) is duplicated code, but that is a source-route concern owned by another lane.
- render_mutation_calibration_json public API is unchanged but the new totals live on the in-memory report only. A minimal JSON-contract unit test pinning the absence of *_total keys across the whole serialized tree (not just known roots) would close the only oracle gap left after this PR.
- Ripr sensor exit code 2 (failed) but PR body does not cite ripr output; relationship between ripr failure and this claim is unverified.
Refuted
- Stale active-view region: a viewer could read truncated Vec content while the total reflects pre-truncate length, yielding an out-of-bounds index or detach-style use-after-resize bug.; refuted because: The report only ever exposes the truncated Vec and the pre-truncate total as separate fields; there is no resizable backing store, no detach/transfer, and no indexer that uses the total to index into the truncated Vec. The note is informational string formatting.
- Worker/async handoff risk from a Vec<Vec<...>> captured total in the report struct could be observable as a UB-relevant unsynchronized read across threads; refuted because: Report is constructed and consumed within a single render call on the calling thread; no Arc/Rc, no channel, no spawn, no async, so there is no cross-thread read of the total that could race with the truncate in the same builder.
- No JS/WASM/async/worker/transfer/detach surface in this diff; language is rust+markdown only, so ub-worker-handoff has no real boundary to audit beyond Rust report cloning.
- JSON totals could leak via new fields the test does not probe.; refuted because: Test probes top-level keys, metrics.missed_runtime_signals_total, and metrics.static_only_findings_total; report struct adds totals in memory only, JSON renderer is untouched in the diff. Risk is bounded by the unchanged JSON renderer path; covered by negative JSON assertion.
Evidence gaps
- Model proof intent was rejected by deterministic validation.
Parked follow-ups
- Devin review noted new sampling tests lack spec mapping; author replied mapping is owned by test-role verification, not this claim's fence.
- Duplicate xtask renderer carries the same disclosure; risk that the two diverge is acknowledged non-blocking by author and is out of this claim.
- MUTATION_CALIBRATION_AGREEMENT_SAMPLE_LIMIT is promoted from private to pub(crate) in xtask and re-exported twice to satisfy the new test. The constant is the same value as MUTATION_CALIBRATION_STATIC_WITHOUT_RUNTIME_SAMPLE_LIMIT (50) and is now visible outside the module. Acceptable for the test but worth a follow-up to deduplicate the two constant names with the same value.
- The product and xtask renderers remain full duplicates; the PR scopes the fix to the disclosure claim and explicitly defers unification. Out of fence, parked.
EffortlessSteven
left a comment
There was a problem hiding this comment.
Independent focused review for #7744 — no actionable findings emitted within the delegated sampling-disclosure scope.
reviewed_head_sha: a14afc5a8b1eb49efa3c5279632f01c3f2fc93cd
integration_basis: exact source parent ff4a2fcd6fac21a93b8fb04f1b0befc80311a601; fetched main 78312b335cdb1558372aded3a4911073052753a9; published PR base d40e2b4c489a163ec00fd3e43ba9c18b83d9e90c.
Observed 2026-10-14 03:27 UTC. Current head re-read before submission and unchanged. Existing Cursor writer retains candidate ownership; no candidate edits or rival implementation.
Changed surfaces and semantic owners inspected: complete six-file diff, issue/latest comment, all-state #7744 PR search, RIPR-SPEC-0006, product calibration report builder/explicit JSON projection/markdown renderer and duplicated xtask path, their tests/re-exports/changelog fragment. Totals are captured before truncation at the builder; markdown uses shown versus total; explicit JSON projections never serialize the added in-memory fields. No platform branch, dependency, process, workflow, packaging, credential or release change is introduced.
Observed independent renderer proof
An isolated Rust 1.95.0 harness compiled the exact-head and exact-parent report/build/render source, using the declared serde_json dependency at repository-lock version 1.0.151. Fixtures contain N ungripped static gaps in src/gap.rs and N unmatched missed mutants in src/other.rs.
| Input N per category | Rows per agreement table | Sampling notes per renderer | Full agreement denominators |
|---|---|---|---|
| 0 | 0 | 0 | 0 / 0 |
| 49 | 49 | 0 | 49 / 49 |
| 50 | 50 | 0 | 50 / 50 |
| 51 | 50 | 2, each “Sample only; showing 50 of 51.” | 51 / 51 |
For every case, both product/xtask agreement sections were byte-equal; both JSON sample arrays had min(N,50) entries. Recursive traversal of every object and array found neither missed_runtime_signals_total nor static_only_findings_total. Each renderer's entire parsed JSON document also equaled its exact-parent document, stronger than root/metrics-only key checks. Under-cap agreement sections equaled baseline; baseline at 51 omitted disclosure.
Discriminating removal controls: independently removed the out.push_str(...) statement inside each renderer's push_agreement_sample_note, leaving the other renderer intact. Each control compiled, passed 0/49/50, and failed the agreement-section parity assertion at 51 (native exit 101). Original source restored; positive rerun exited 0. These were disposable harness experiments, never candidate changes.
Harness command: RUSTUP_HOME=/workspace/pr7841-rustup CARGO_HOME=/workspace/pr7841-cargo /workspace/pr7841-cargo/bin/cargo run --manifest-path /workspace/pr7841-proof/Cargo.toml.
Witness SHA256: positive d6f4fd67f9a67bff4f91da48ad9c96ca06141a42f80588248245996fa9c0bd13; product-removal 4b3af2e08e91a84d28547a29ce5f076a12e0ad25ac19aa526394bae6e94dc0ec; xtask-removal 23ca821f7eb8d2eb44870fa2bf1ce6d82be67c3ddac1a09d85dfb2c980383f70.
Hosted evidence directly inspected
Routed Rust Small run 38499938016, job 115644325969, checks out merge candidate fcffdc16c310a0f3283043119c3483c926c41f58 (this head into d40e2b4c…). Its logs show both new sampling tests PASS and nextest summary 15,514 executed, 15,514 passed, 2 skipped, followed by doctests 2 passed / 1 ignored. This is combined-tree hosted proof, distinct from the focused exact-head harness. No duplicate CI dispatched. Latest observed Droid Auto Review remained queued; skipped advisory/irrelevant jobs are not passes.
Refuted/stale findings: the spec-mapping thread is resolved with a source-backed reply. SPEC-0006 already describes these sample lists; PR body names the new discriminating tests and explains the fenced ledger omission. No ledger/spec expansion required for this delegated verification.
Proof limits and residuals: narrow harness excludes xtask command/import plumbing and existing test modules; product snapshot-head helper is an unexercised shim and JSON formatting wrapper uses serde_json plus newline. Harness transitive dependencies resolve independently, so this is not full locked-workspace qualification. N=0 exercises the report builder, not successful empty CLI import (product CLI rejects zero recognized mutant records). Cross-renderer whole-report parity, CLI routing, full current-base merge proof, protection/readiness and release qualification are not claimed. Existing tests' root/metrics-only JSON assertions could be strengthened recursively as non-blocking test hardening; this review independently checked the whole tree.
All explicit fences preserved: no OUTPUT_SCHEMA.md, traceability.toml, CHANGELOG.md, suppression/check surfaces or inherited golden re-blessing. Review worktree removed; source/logs/rendered outputs and frozen witnesses retained locally under /workspace/pr7841-proof for reproduction, not represented as remotely uploaded artifacts.
disposition: REVIEW_INCOMPLETE for overall merge readiness; no blocking semantic/source defect found in this delegated scope. Parent retains qualification/integration and fresh gate assessment. No Ready, merge, release, deployment, production-cutover or upstream action taken.
EffortlessSteven
left a comment
There was a problem hiding this comment.
review-pr (published head, author COMMENT)
GitHub cannot request changes from this author identity; COMMENT plus an explicit disposition is the review event, not approval.
reviewed_head_sha: a14afc5a8b1eb49efa3c5279632f01c3f2fc93cd
integration_basis: source parent ff4a2fcd6; published PR GitHub base d40e2b4c (behind-only vs later main; no restack)
claim_boundary: markdown-side sampling disclosure for truncated calibration agreement tables; no new JSON fields; #7760 surfaces untouched
changed_surfaces_and_semantic_owners_inspected:
- crates/ripr/src/output/mutation_calibration.rs (builder captures pre-truncate totals; markdown push_agreement_sample_note; JSON projection still serializes capped arrays only)
- xtask/src/reports/mutation.rs (duplicate renderer, same disclosure)
- xtask tests/re-exports (heading strings Runtime signals without static gaps / Static gaps without runtime signals preserved)
- changelog.d/7744-calibration-agreement-sample.md
- complete six-file diff; RIPR-SPEC-0006 sample-list contract; no OUTPUT_SCHEMA.md / CHANGELOG.md / traceability.toml / check.rs / suppressions.rs
blocking_findings: none
non_blocking_suggestions:
- product and xtask remain duplicated full calibration renderers; unification is out of this claim
- JSON negative assertions are root/metrics-key rather than a whole-tree walk; independent harness already checked the whole tree
refuted_or_stale_findings:
- Devin spec-mapping thread PRRT_kwDOSiSx0c6sIwM- resolved after source-backed reply (SPEC-0006 already contracts samples; ledger edit fenced; check-traceability does not enumerate new tests)
- CodeRabbit docstring-coverage inconclusive is not a repository gate and must not churn the head
- ub-review COMMENT: stale active-view / worker-handoff / JSON-leak hypotheses refuted; remaining JSON whole-tree test and ripr-sensor notes are non-blocking
proof_and_ci_observed:
- local red/green on agreement_tables_disclose_sampling_when_truncated (0 vs 2 sample notes, then pass) plus under-limit negative
- hosted required check Ripr Rust Small Result SUCCESS (job 115660616977, run 38499938016) on this head
- implementation job Ripr Rust Small on GitHub Hosted / Rust gates SUCCESS (job 115644325969): Required Rust tests, doctests, Golden output contracts, Fixture contracts all success
- independent COMMENT review ran isolated 0/49/50/51 harness with removal controls; both renderers emit Sample only; showing 50 of 51 at N=51 and omit the note at N<=50; JSON recursive walk found no *_total keys
- cargo-deny, dependency-review, ub-review, Graphite mergeability_check, GitGuardian success
- skipped-by-policy (msrv, vscode, rust-coverage, windows-advisory, rust-tests-junit, future-clippy, docs gate, unused routed runners) are not passes
proof_or_review_missing:
- classic branch-protection API 403 (ruleset 18845973 readable: 0 approving reviews, thread resolution required, squash allowed; no required-status-check rule in that ruleset)
- Gemini quota skip = missing Gemini review, not clean review; adequate alternatives used (this pass, independent COMMENT, CodeRabbit, ub-review, Devin with reply)
- advisory droid-review still queued with no runner (policy/ci-lane-whitelist.toml posture=advisory); missing for that provider, not a required gate
affected_currentness_dimensions: production implementation, test stimulus, test oracle, public markdown claim, candidate head identity, exact-head CI receipts (now terminal for the required result job)
residual_assumptions_and_non_claims:
- JSON lists remain a 50-row sample; markdown names the pre-truncation count only when truncated
- does not prove runtime mutation results, markdown completeness above 50 rows, or renderer unification
- hosted Golden output contracts success on this merge candidate is distinct from the inherited local owner_return_pin_fallible_literal drift recorded on clean origin/main
disposition: REVIEW_READY
Oracle: omitting push_agreement_sample_note or capturing totals after truncate still presents 50 rows as the full set and fails the 51-row unit test. Under-limit fixtures fail if the note is always emitted. JSON grows a total field only if the schema fence is broken, which the JSON assertions reject.
No unresolved review threads. Required Ripr Rust Small Result is success on this exact head. Proceeding to protected squash merge.
Summary
The
ripr calibratemarkdown tables for "Runtime signals without static gaps" and "Static gaps without runtime signals" were silently truncated at 50 rows. They now discloseSample only; showing N of Mwhen truncated, using the pre-truncation count, while JSON lists stay capped with no new schema fields.Closes #7744.
Swarm / Source Boundary
This PR targets
EffortlessMetrics/ripr-swarm, the normal development trunk fortrusted same-repo
riprwork. Confirm the change belongs here:dependency, or repo-ops development for
ripr-swarmsurface
Source-of-truth Links
Proposal: n/a (honesty disclosure for an existing advisory report)
Spec: RIPR-SPEC-0006 (mutation calibration report)
ADR: n/a
Plan item: n/a
Governing issue or accepted claim: #7744
Acceptance delta: truncated agreement markdown tables name the sample cap and pre-truncation count instead of presenting 50 rows as the full set.
Candidate Relationships
Candidate branch (GitHub PR head is authoritative after publication):
cursor/calibrate-agreement-sample-bb51Stack parent or prerequisite PR (if any): none
Proposed replacement of PR (if any; not yet accepted): none
Acceptance retained from a replaced candidate (if any): none
Accepted winner and losing candidate disposition (when decided): n/a
Searched all-state PRs and current
origin/main(ff4a2fcd6) before publication; no equivalent implementation of #7744 exists.Scope
Markdown-side sampling disclosure for the two silently truncated calibration agreement tables, plus the duplicated
cargo xtask mutation-calibrationrenderer so the same lie is not left on the xtask path.Scope Classification
This PR is scoped by:
Production delta:
missed_runtime_signalsandstatic_only_findingson the in-memory report.Sample only; showing N of M.above the table.Evidence/support delta:
agreement_tables_disclose_sampling_when_truncated(and the xtask twin) with 51 unmatched missed mutants and 51 static-only gaps.Sample only; showing.changelog.d/7744-calibration-agreement-sample.md.Single acceptance criterion:
When either agreement table is truncated, the markdown names that it is a sample and the pre-truncation count; JSON schema is unchanged.
Non-goals:
docs/OUTPUT_SCHEMA.mdedits (docs/OUTPUT_SCHEMA.mdis contested).--limit/ no-limit flag..ripr/traceability.toml,cli/commands/check.rs, orsuppressions.rs(ux(suppress): test_efficiency entries in a check --suppression-policy are silently ignored with no warning #7760 is separate).owner_return_pin_fallible_literalgoldens (inheritedorigin/maindrift, reproduced on exact baseff4a2fcd6).Support-tier Impact
docs/status/SUPPORT_TIERS.mdClaim/proof notes:
Advisory markdown wording only. JSON contract and support-tier claims are unchanged.
Policy Impact
Ledger or exception notes:
Proof
Result, failures, or skipped proof:
0sample notes vs2) and passed after.fixtures/boundary_gap/calibration/**/mutation-calibration.md) did not need re-blessing: existing fixtures are under the 50-row cap, so the new note is omitted.goldens checkfails onowner_return_pin_fallible_literalon cleanorigin/mainas well; not this claim.Claim Boundary
What may be claimed after this PR? Truncated calibration agreement markdown tables disclose sampling and the pre-truncation count.
What must not be claimed yet? JSON now carries the full count; markdown is complete above 50 rows; runtime mutation results; that the duplicate xtask/product renderers were unified.
Rollback
Revert the squash commit. Markdown returns to silently truncated tables; JSON is unchanged.
Spec-Test-Code Traceability
crates/ripr/src/output/mutation_calibration.rs::agreement_tables_disclose_sampling_when_truncated;xtask/src/tests.rs::mutation_calibration_agreement_tables_disclose_sampling_when_truncatedcrates/ripr/src/output/mutation_calibration.rs;xtask/src/reports/mutation.rsStatic Language Check
killed,survived,untested,proven, andadequate.CI Economics
Engineering Check
panic,unwrap,expect,todo, orunimplementedin production code.panic,unwrap,expect,todo, orunimplementedin tests.Gates
Local:
cargo xtask precommit(pass). Hosted merge-gate matrix is the remaining proof.Exact candidate SHA:
a14afc5a8b1eb49efa3c5279632f01c3f2fc93cd