Skip to content

fix(analysis): credit a range-bound change only at an input that separates the old and new ranges (supersedes #14450) - #14529

Merged
EffortlessSteven merged 27 commits into
mainfrom
claude/project-thread-9xace9
Nov 15, 2026
Merged

EffortlessSteven merged 27 commits into
mainfrom
claude/project-thread-9xace9

Conversation

@EffortlessSteven

@EffortlessSteven EffortlessSteven commented Nov 12, 2026 •

Copy link
Copy Markdown
Member

Requested by Steven · project thread

Summary

Supersedes #14450. That PR is stuck in the merge queue on head 18fa6f19 (pushes refused with GH006, dequeue refused) and that head has a confirmed false credit: a sum/product returned through type Byte = u8 can wrap to the old value while ripr reads exposed. This branch is #14450's head plus the fix commit (c64b5640), main merged in, and a spec sentence for the new limit.

  • A changed range bound read exposed 1.00 when the only test asserted an input where both ranges agree ((0..n).sum() → (0..=n).sum() with assert_eq!(sum_to(0), 0)). Infection read yes for any reachable test.
  • The integer fold (value_contradiction.rs) now evaluates owners whose whole body is a range reduction (sum/count/product, optional as cast), a range contains(&x), or a match on one parameter with literal/range/_ patterns.
  • changes_only_a_range_bound (infection.rs) gates a non-predicate change confined to one range expression only when the range feeds an absorbing consumer: a method on the range's chain outside LENGTH_PRESERVING_METHODS (sum, contains, find, any, take, filter, ...), a for header, or a match range pattern. Length-preserving chains (.iter().map(..).collect(), slicing, .len(), .count()) keep the ordinary reading, since one element more shows at every non-empty input.
  • A gated change reads infection yes only when an assert_eq!-family or bare boolean assert! holds a bare literal owner call (or its .await) that folds differently on the two versions; weak when only a relational/assert_ne! check separates them, or every asserted call agrees (not claimed for an equivalent rewrite or when the owner has other callers); unknown otherwise.

Breadth measurement

  • Goldens/fixtures: cargo xtask goldens check passes with zero changed outputs; no existing fixture or golden changes class.
  • Agent-eval inclusive_range scenario (feat(xtask): answer-keyed agent eval for tokens to the answer and loop closure (#14298) #14335), run by hand on its exact files: existing test sum_to(0) exposed → weakly_exposed; weak test assert!(sum_to(4) > 0) weakly_exposed → weakly_exposed; reference assert_eq!(sum_to(4), 10) exposed → exposed.
  • Real-code survey (regex approximation over 395 crates in the local cargo registry, 10,510 non-test lines containing a range): 16.4% would be gated (1,137 absorbing chains led by contains 175, find, starts_with, all, next, filter; 588 match range patterns), 62% keep the ordinary reading, 21.6% are for headers with no probe today. A first version gated every range change and would have downgraded about 80% of these lines; it was narrowed before review.

Source-of-truth Links

Proposal:
Spec: RIPR-SPEC-0001 (static exposure loop)
ADR:
Plan item:
Governing issue or accepted claim: #14419
Acceptance delta (one sentence): A changed range bound is credited as exposed only when an exact or boolean assertion's literal input makes the old and new ranges give different results; otherwise it reads weakly_exposed or infection_unknown.

Candidate Relationships

Candidate branch: claude/project-thread-9xace9 (from claude/project-thread-0ujkvf at 18fa6f1)
Stack parent or prerequisite PR (if any): none
Proposed replacement of PR (if any; not yet accepted): #14450

Scope

Shapes checked end to end with a debug ripr against main (before → after):

Shape Test main this PR
(0..n).sum()→(0..=n) sum_to(0) == 0 exposed weakly_exposed
same sum_to(4) == 10 exposed exposed
same assert!(sum_to(4) > 0) weak weak
(0..n).count() as u32→..= == 1 at 0 exposed exposed (not gated)
(1..n).sum()→(0..n) (equivalent) sum_to(3) exposed infection_unknown
(0..10).contains(&x)→..=10 inside(3) exposed weakly_exposed
same inside(10) exposed exposed
match 0..=5 =>→0..5 => tier(3) weak weakly_exposed (infection weak)
same tier(5) exposed exposed
v[..n].iter().sum()→..=n extra element 0 exposed infection_unknown
(0..n).collect()→..= upto(2) exposed exposed (length-preserving, not gated)
unread input (env::args) exposed infection_unknown
&s[..n]→&s[..=n] whole index unchanged (excluded by design) unchanged
<→<= predicate, for loop range unchanged unchanged

Non-goals: for-header range probes (#11399, no probe exists), folding Vec/slice results.

Proof

On b193ce71b3e8978822d7cde616ee604b91167480, and again after merging main at 24505206c6f80375c873d541bdc9720f7db415fe:

cargo test -p ripr --test range_bound_edit         # 44 passed, exit 0
cargo xtask verdict-corpus check-all               # exit 0
cargo fmt --check                                  # exit 0
cargo clippy -p ripr --all-targets -- -D warnings  # exit 0 (b193ce71)
cargo xtask goldens check                          # exit 0, no changed outputs
cargo xtask check-evidence-promotion-honesty       # exit 0
cargo xtask precommit                              # exit 0 (b193ce71)

Red controls: with the line-reach check in range_change_visibility disabled, a_dead_assertion_does_not_supply_a_separating_input, an_assertion_after_return_on_the_same_line_does_not_separate and an_assertion_in_an_uncalled_closure_does_not_separate fail (41 passed, 3 failed). With only the 004b0e53 source change stashed, the same-line return test fails alone (42 passed, 1 failed). After main merged at 24505206c6f80375c873d541bdc9720f7db415fe, shared_cfg_gate_owner_pin (from #14470) also passes.

Run with CARGO_PROFILE_DEV_DEBUG=0 and low job counts (memory-limited container).

Claim Boundary

Static advisory only. Known fail-closed false negatives: an absorbing range ripr cannot fold (v[..n].iter().sum(), .find(..), non-literal inputs) reads infection_unknown even when the test does separate. Known residual: length-preserving chains keep the ordinary credit, so a moved start where both ranges are empty at the test input ((1..n).collect() → (0..n).collect() at n=0) is still credited.

Review hardening (rounds 1 to 4) also refuses a separating input when:

  • the call is wrapped;
  • the call is a self-comparison;
  • the owner has other callers;
  • the test body has a use naming the owner or a glob import;
  • the test body has a local const, static, closure parameter or pattern named like the owner;
  • intermediate arithmetic in a match arm is not folded;
  • the other side of an exact assertion is not a literal (a helper such as reference(4) that calls the owner moves in lockstep);
  • the test is #[ignore]d or #[should_panic], or rebinds, reassigns or re-reads the expected binding;
  • the literal is not the current result (an old-value literal);
  • the assertion never runs: it sits in a literal-false block, in an uncalled closure or after a return, including a return; on the same line;
  • a match arm is #[cfg]-gated, or a nested arm shares the edited arm's head;
  • a range is handed to a call (Iterator::sum(0..=n)), while v.get(a..b) forms slice like v[a..b];
  • a sum or product whose accumulator width is not a written integer return type (an unresolved alias such as type Byte = u8, or an as cast) is not folded, since the real owner could wrap to the old value. count() keeps folding (usize accumulator).

A match-arm probe that carries only the arm head now recovers the full arm line, which also fixes an exposed reading on main for arm-body range edits. Arm-body ranges at a separating input read infection_unknown (fold limit). A moved match range pattern whose arms the fold cannot read (&str results) keeps the ordinary infection reading, so the arm-routing evidence (#5992) still credits a moved input; the hosted verdict corpus (spec0229-range-widened-*) caught this. File-level shadowing of the owner name is pre-existing and filed as #14466. Range-bound shapes the gate doesn't recognise still keep main's yes (a let-bound range, two ranges edited on one line, endpoint moves in matches! or if let patterns, and dead code the lexical reach scan can't see). Those are filed as #14538. None of them is a new credit.

Rollback

Revert the squash commit; no schema or output contract changes.

Spec-Test-Code Traceability

  • Spec: RIPR-SPEC-0001 (range-bound rule stated under Behavior); RIPR-SPEC-0108 (honesty corpus)
  • Fixture: fixtures/rust_range_bound_agreeing_input (main: exposed, this PR: weakly_exposed) plus corpus case rust_range_bound_agreeing_input
  • Tests: crates/ripr/tests/range_bound_edit.rs (44)
  • Code: analysis/classify/infection.rs, analysis/test_grip_evidence/value_contradiction.rs

Static Language Check

  • Static output avoids killed, survived, untested, proven, and adequate.
  • Unknowns include stop reasons where applicable.

CI Economics

n/a

Source review: REVIEW_READY ac8c2ee

Merged main at ac8c2ee55ff1021b685592470122ad4628419dc5 to resolve a conflict with #14393 (#14388): both helper families were inserted at the same spot in infection.rs, and the merge keeps both. On this head: range_bound_edit 44/44, lib classify::infection 31/31 (including #14388's test), and verdict-corpus check-all, clippy --all-targets -D warnings, goldens check, honesty and check-traceability all exit 0. An independent review of the merge found nothing dropped or duplicated, and the two branches sit in different probe families.

The mixed-line dead-assertion finding is fixed in 004b0e53, with regressions in b193ce71. Independent reviews: one of the full head at 3d3f04ff and one of the 004b0e53 delta. Neither found a regression; the four pre-existing shapes they found are in #14538.

https://claude.ai/code/session_01YVdGzU8UfNNxxcYuAKZ3YY


Generated by Claude Code

…arates the ranges (#14419)

A changed range bound ((0..n).sum() to (0..=n).sum(), a moved start, a
contains bound, a match range pattern) changes the owner's result only at
inputs where the old and new ranges yield different values. Infection
read yes for any reachable test, so assert_eq!(sum_to(0), 0) credited the
change as exposed although it passes on both versions.

The integer fold now evaluates an owner whose whole body is a range
reduction (sum/count/product, optionally cast), a range contains, or a
match on literal and range patterns. A non-predicate change that only
moves a range bound reads infection yes only when an exact or boolean
assertion holds a literal call that folds differently on the two
versions; weak when only a relational check separates them or every
asserted call agrees; unknown otherwise.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…d self-comparison credit (#14419)

A registry survey (395 crates, 10.5k range lines) showed the first gate
would downgrade most range code, where a length-preserving chain shows
one element more at every non-empty input. Gate only ranges whose chain
reaches a method outside a length-preserving list, a for loop, or an
unparseable match range pattern (~16% of lines).

Review fixes: a wrapper around the owner call (is_positive(sum_to(3)))
no longer grants exact credit; an assertion naming the owner twice is
unread; every-input-agrees is not claimed when the owner has other
callers.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…it; read match-arm endpoint moves (#14419)

Review repairs on #14450:
- a test body with a use item naming the owner (a nested rival import)
  is unread for the separating-input proof;
- the range-tail fold reads only literal or parameter operands, so
  (n + 1) / 2 at n: u8 = 255 is not folded to an untyped 128 and a
  passing release-mode assertion is not read as contradicted;
- match-arm heads are compared against their baseline head, and arm
  lines and block headers are parsed in a match or with their block
  closed, so 1..5 => to 0..5 => is gated too;
- tests for the other-callers guard, the scoped import, the typed
  arithmetic refusal and the moved match-arm start.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…read arm-body range edits (#14419)

Review round 3 on #14450:
- a glob use item in the test body is unread for the separating-input
  proof (it may bind the owner's name);
- aligned_range_texts cuts at an arm arrow only when one side is a bare
  arm head, found in masked text, so arrows in comments, strings or a
  one-line match no longer hide the changed range;
- a head-only match-arm probe whose edit sits in the arm body reads the
  owner's whole arm line, so _ => (0..n).sum() to (0..=n) is gated
  instead of credited by any reachable test;
- range_consumer looks for range expressions inside a parsed arm too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…owner name

A test-body const, static, closure parameter or pattern named like the
owner makes a later call name something the fold does not evaluate, so
it no longer supplies a separating input. Also use then_some per clippy.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…esty-corpus control

RIPR-SPEC-0001 states the absorbing-consumer gate and its yes/weak/unknown
outcomes. The rust_range_bound_agreeing_input fixture (main reads exposed,
this branch weakly_exposed) joins the evidence-promotion honesty corpus as
an independent must_not_promote case (#14419).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…ing when the arms don't fold

A range pattern routes an input to another arm; when the fold cannot read
the arm results (a &str match) the gate returned unknown and dropped the
moved-input credit the verdict corpus pins (spec0229-range-widened-*).
Patterns now keep the ordinary yes in that case; folded arms still read
yes/weak from the asserted inputs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…side input for &str match patterns

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…idth is unknown

An unresolved return alias (type Byte = u8) or a cast leaves the sum's
width unknown, so (34u8..41).sum() could wrap to the baseline's 3 while
the fold reported 259 and credited a separating input. Count keeps
folding (usize accumulator).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzSmybWobP8wMmfhQ22
…-9xace9

# Conflicts:
#	docs/specs/RIPR-SPEC-0001-static-exposure-loop.md
@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Explain Change →

Summary by CodeRabbit

  • Bug Fixes
    • Improved analysis of changes to range bounds. Findings now distinguish tests that demonstrate changed behavior from tests whose inputs produce the same result before and after the change.
    • Reports classify non-distinguishing evidence as weakly exposed, and use an unknown status when the impact cannot be determined.
    • Range changes consumed by operations that preserve range length are handled separately from changes that may alter the resulting value.
  • Documentation
    • Clarified how range-bound changes and test evidence affect exposure classifications.

Walkthrough

The analyzer now classifies changed range bounds based on range consumers and test evidence. Added tests, specifications, traceability entries, and a fixture cover cases where inputs separate the old and new results and where they agree.

Changes

Range-bound analysis

Layer / File(s) Summary
Test evidence and range evaluation
crates/ripr/src/analysis/test_grip_evidence.rs, crates/ripr/src/analysis/test_grip_evidence/value_contradiction.rs
Test evidence distinguishes exact assertions that separate old and new results, inexact assertions, and inputs where results agree. Range-shaped expressions gain bounded evaluation for reductions, membership checks, and parameter matches.
Range detection and infection classification
crates/ripr/src/analysis/classify/infection.rs
The analyzer detects changed range bounds and identifies whether ranges are patterns, feed absorbing consumers, or occur in preserving contexts. Exact separating assertions can yield Yes; inexact or agreeing evidence yields Weak; some unestablished changes yield Unknown.
Tests, specification, and fixture
crates/ripr/tests/range_bound_edit.rs, docs/specs/RIPR-SPEC-0001-static-exposure-loop.md, .ripr/traceability.toml, .ripr/traceability.d/*, changelog.d/*, fixtures/rust_range_bound_agreeing_input/*, fixtures/evidence-promotion-honesty-corpus/cases/*
Integration tests cover range edits, consumer contexts, assertions, and unevaluable cases. The specification and changelog describe the classifications. The fixture changes sum_to from an exclusive to an inclusive range and expects a weak finding when its test calls sum_to(0), where both versions return zero.

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

Sequence Diagram(s)

sequenceDiagram
  participant OwnerAnalysis as infection_evidence_for_owner
  participant ConsumerAnalysis as Range consumer analysis
  participant TestEvidence as range_change_visibility
  participant InfectionClassification as range_bound_infection
  OwnerAnalysis->>ConsumerAnalysis: Identify changed range and consumer kind
  OwnerAnalysis->>TestEvidence: Evaluate assertions and old/new results
  TestEvidence-->>InfectionClassification: Return range-change visibility
  ConsumerAnalysis-->>InfectionClassification: Return consumer kind
  InfectionClassification-->>OwnerAnalysis: Return infection classification
Loading

Possibly related issues

  • Issue 11399: The PR classifies range-bound changes based on whether an input separates the old and new ranges, covering the reported for-header case.
  • Issue 14419: The new fixture covers the reported case where the only test uses n = 0 and both range versions agree.
Merge Risk: Moderate · up to 10d51

The new range-bound gate can still report a changed range as exercised by a test that does not observe it, for example through dead assertions, shadowed or imported callees, nested match arms, or associated-function sums. Reports can be falsely reassuring in these edge cases. Fix these paths or accept them explicitly before merging.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: a range-bound change is credited only at an input that separates the old and new ranges. It matches the changeset, which gates range-bound infection credit on separati…
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.
Description check Passed The description is largely complete against the template. It states the summary, the source-of-truth links (governing issue #14419, spec RIPR-SPEC-0001, acceptance delta), candidate relationships (sup…
Full details: Title check

Explanation

The title names the main change: a range-bound change is credited only at an input that separates the old and new ranges. It matches the changeset, which gates range-bound infection credit on separating assertions. The title also carries a parenthetical supersession note, which is slightly noisy but does not make it misleading.

Full details: Description check

Explanation

The description is largely complete against the template. It states the summary, the source-of-truth links (governing issue #14419, spec RIPR-SPEC-0001, acceptance delta), candidate relationships (supersedes #14450, candidate branch), scope and non-goals, a support-tier-free claim boundary, proof commands with results, rollback, spec-test-code traceability, a static language check, and CI economics marked n/a. Gaps: the Swarm / Source Boundary section is not checked off, the Scope Classification checkboxes and Policy Impact checkboxes are not ticked, the Support-tier Impact section is not addressed, and the Gates checklist is not marked. The Proof section lists commands run, but not every gate in the template (for example cargo fmt was run, but check-spec-format, check-fixture-contracts and others are not reported). The ADR and Plan item fields are blank. The Engineering Check section is not addressed. The core content is present, so the check passes, but the template boxes should be completed.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

A rabbit checks the bounds at dawn,
And tests each path the ranges spawn.
When old and new results agree,
The finding stays weak, not certainty.
Then hops away through fields of green.

gemini-code-assist[bot]

This comment was marked as resolved.

Copy link
Copy Markdown
Member Author

Carrying forward the independent alias-width repair evidence from #14450: prepared repair 9910a171 passed 26 range-bound tests on Linux/Rust 1.95, including six local full-pipeline controls. Equal wrapped alias sum/product and cast sum results became InfectionUnknown, while explicit-width genuine sum and count separation remained Exposed. I verified value_contradiction.rs is byte-identical between that reviewed repair and current successor head 257ed9b4. This supports the repaired fold seam, not a fresh whole-successor test run or hosted qualification; current-main integration and the full successor review/qualification remain required. No duplicate branch repair or CI was started.

@EffortlessSteven EffortlessSteven left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

SOURCE_REVIEW_READY for head 043ae96

Independent subagent review of the repair delta over 18fa6f1 (fold guard in value_contradiction.rs, two new tests, spec sentence, merge resolution). It traced the refusal path to an unknown infection reading with no exposed credit, and confirmed both new tests discriminate and the conflict resolution kept every main paragraph. Non-blocking notes: no direct test of the cast arm (a sum followed by a cast needs a turbofish, which RangeTail already refuses), and the spec wording, now named as fixed-width types. The Gemini note on spaced macro bangs was answered: an unrecognized assertion withholds credit. Local proof is listed in the PR body.


Generated by Claude Code

@EffortlessSteven
EffortlessSteven marked this pull request as ready for review November 12, 2026 22:49

@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 1 potential issue.

Devin Review

…eral (#14419)

assert_eq!(sum_to(4), reference(4)) with a helper that calls sum_to moves
both sides together, so it holds on both versions; the direct call alone
used to earn ExactInputSeparates. The other operand must now be an integer
literal expression, true/false, or a plain string literal.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzU8UfNNxxcYuAKZ3YY

Copy link
Copy Markdown
Member Author

Independent source review of head 613236a105a4a726700764eefc90d670cdb07e18: one remaining potential false-credit path in the new pinned-literal guard needs a focused regression before qualification.

let expected = 10;
for expected in [sum_to(4)] {
    assert_eq!(sum_to(4), expected);
}

For the same (0..n).sum() → (0..=n).sum() owner, both actual operands here change together (6 → 10), so the assertion passes on both versions. However, assertion_operands resolves expected through let_initializer, whose whole-body scan finds the outer plain let expected = 10 and does not account for the for pattern shadow. The resolved operands become sum_to(4) and 10; is_pinned_literal accepts 10 and the exact-credit return occurs before the final mention-count check. body_imports_same_name only guards bindings of the owner's name, not this expected operand. The sibling let (expected,) = (sum_to(4),); shadow after the outer literal binding needs coverage too.

This is a source-traced finding, not a claimed executed production-path reproduction. Please validate these shapes in the existing range_bound_edit harness and refuse credit unless the resolved expected binding is proven live and unshadowed (or restrict this positive path to syntactically literal operands). Retain an unshadowed literal-binding/direct-literal positive control and the helper/alias-width negatives. No duplicate build, branch change, CI run or review request was started by this review.

…14419)

Review of 613236a found three more false credits: an expected binding
rewritten by a compound assignment (expected |= sum_to(4)), a literal only
the old range returns, and an #[ignore] test. An exact separating input now
needs the pinned literal to equal the current folded value, a let operand
whose name appears only in its binding and the assertion, and a test that
is not ignored.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YVdGzU8UfNNxxcYuAKZ3YY

Copy link
Copy Markdown
Member Author

Independent hosted-receipt follow-up for head 24505206c6f80375c873d541bdc9720f7db415fe, base bb5040a05cf4c3f3ac422eade17ed1c8c4912219, executed integration 33695b786c8c87122c1bc3aad7db8f8e7fe1036d in existing Merge-ready run 43345062655, attempt 1.

I inspected the actual four shard logs, not just the aggregate badge. All 44 ripr::range_bound_edit cases show PASS (7/13/10/14 across shards). In particular, shard 1 job 131622761141 passes the uncalled-closure negative and live-same-line positive; shard 2 job 131622761402 passes the dead-block and unresolved-width-alias negatives; shard 4 job 131622761323 passes the same-line-return negative. This supplies independently inspected hosted green receipts for the previously source-only reach repair; the author's mutation/red controls remain author-reported, not re-executed here.

Verifier job 131634237060 executes verify-test-shards bound to that integration SHA, run ID, attempt 1 and four shards: 29,551 workspace tests / 29,551 JUnit tests, zero duplicate, missing or extraneous tests. Combined artifact: 14002762363, SHA-256 654b783b084658dad2c636e801ac8ecfb2d18710cbb27e70dcaf48166a6c2b12.

Qualification is still in progress: Rust gates have passed both strict Clippies, goldens, fixtures, verdict corpora and doctests, but PR evidence/final Result are not yet terminal. This is a receipt checkpoint, not cumulative review or merge clearance. Continue the existing run; no duplicate qualification or ordinary development Actions requested.

Copy link
Copy Markdown
Member Author

Exact-head qualification completion follow-up for 24505206c6f80375c873d541bdc9720f7db415fe, integration 33695b786c8c87122c1bc3aad7db8f8e7fe1036d, run 43345062655, attempt 1.

The existing run has now completed successfully. I inspected the Rust-gates and final Result logs: PR evidence contract passed at 02:26:39 UTC; summary contract passed; schema producer sweep validated the live PR evidence and wrote its report for the tested integration. Final Result job 131645826367 passed at 02:27 UTC after current-head review/eligibility rechecks, with GITHUB_PR_EVIDENCE=produced, Rust gates success and sharded tests success. The prior independently inspected 44 range regressions and 29,551-test complete/disjoint verifier receipt still apply to this same run and head.

Fresh review-thread read shows all eight resolved; published head is unchanged and PR remains open/Ready. This establishes terminal qualification, not a merge receipt. Native merge queue/protections remain required. My current native queue read is HTTP 403 rate-limited, so queue admission is not verified and I have not attempted a duplicate admission or direct merge. No rerun is needed.

@EffortlessSteven
EffortlessSteven added this pull request to the merge queue Nov 13, 2026

@EffortlessSteven EffortlessSteven left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

SOURCE_REVIEW_READY
VERDICT: APPROVE 2450520 — no blocking findings on this head.

Independent exact-head review of the range-bound infection gate (#14419), superseding #14450.

Gate. The new else if is the last branch before the ordinary Yes, so a non-range change (or a range shape range_bound_change cannot parse) falls through unchanged. range_bound_change requires the changed span to sit inside a range expression on both sides, returns None when either side's consumer is length-preserving, and only then gates. range_change_visibility credits Yes in exactly two ways: an exact assert_eq!-family or bare boolean assertion whose literal equals the current folded value and differs from the baseline, or a match-arm pattern whose arms the fold cannot read (the pre-existing #5992 reading). Everything else downshifts to weak/unknown, so the gate can only remove credit, not add it except through the new fold.

Fold. RangeTail is conservative: a pure tail, no statements, endpoints/arm values restricted to one literal or parameter, no guards, no turbofish, no #[cfg] arms. sum/product require a written fixed-width return type and reject any cast; count accumulates in usize; within rejects any value outside the declared return width or cast, so a release wrap is None, not a value. contains uses half-open bounds with checked_add; match is first-hit over literal/range/wildcard arms. reduce handles empty accumulators (0/1) and rejects negative starts and products over 64 terms. read_call only accepts a bare owner(literals) or its .await, folds each argument, and pinned_to refuses a literal that is not the current value, so an old-value or impossible assertion cannot separate.

Evidence at this head. Ripr Rust Small Result (ruleset-required) and Admit PR Candidate pass. I confirmed from the hosted shard-1 log that ripr::range_bound_edit cases actually ran and passed (e.g. an_unread_input_does_not_credit_a_changed_range_bound, a_live_assertion_sharing_a_line_still_separates), not only that the crate compiled. The Rust gates job reports precommit: success, goldens: success, and verdict-corpus: 4 corpora checked with 0 false verdicts/contradictions. The new honesty case is must_not_promote, and the fixture expectation is weakly_exposed with infect: weak.

Non-blocking.

  1. The body's one-line "Acceptance delta" is broader than the code and the spec: length-preserving chains (.count(), .collect(), slicing) keep the ordinary Yes even at an asserted input where both ranges agree (a moved start at n = 0). The spec sentence and the Claim Boundary both disclose that residual; only the acceptance sentence omits the carve-out, so I read it as a wording defect, not a behavior gap.
  2. A range change in a context range_consumer cannot parse and that is not the ..→..= insertion falls back to the ordinary Yes; the body already files that as #14538.
  3. The fold is reached by every fold_function_value caller, not only the new gate; no existing expectation or golden changed at this head, and the corpus reports no new contradiction, but that blast radius is worth remembering.

Not checked: no local build or test run; the hosted gates and the observed PASS lines are the execution evidence. I did not re-derive the 16.4% / 62% registry survey.

Read-only: one review and one git fetch; no branch, worktree, label, queue or merge change.

@EffortlessSteven EffortlessSteven left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

VERDICT: APPROVE 2450520 — no blocking findings on this head.

The change gates a changed range bound only when the range feeds an absorbing consumer (sum/product/contains/find/any/take/filter/for header/match pattern) and credits infection only when a related test's asserted literal input folds to different values on the baseline and the change. Length-preserving chains (.iter().map(..).collect(), slicing, .len(), .count()) keep the ordinary reading. The fold handles closed integer reductions, contains(&x), and a match on one parameter with literal/range/_ arms; it refuses unresolved accumulator widths (type Byte = u8), casts, negative starts, products over 64 terms, and values outside the declared return width. The assertion reader refuses wrappers, self-comparisons, other callers, use/glob imports, local const/static/pattern bindings, ignored/should_panic tests, dead assertions, non-literal expected values, and old-value literals.

I checked the issue #14419 repro ((0..n).sum() → (0..=n).sum() with assert_eq!(sum_to(0), 0)) against the new path: the range is absorbing, the fold agrees at n=0, and versions_differ_on_small_inputs is true, so the result is weakly_exposed, not exposed. The separating input sum_to(4) == 10 returns exposed. The 44-test range_bound_edit suite covers the positive and negative shapes named in the PR body, and the hosted Rust lanes and Ripr Rust Small Result are green at this head.

Known residual, not a regression: length-preserving chains keep the ordinary credit, so a moved start where both ranges are empty at the test input ((1..n).collect() → (0..n).collect() at n=0) is still credited. The PR body names this and files the unrecognised shapes in #14538. It is outside the issue's absorbing-consumer repro.

Evidence: gh pr diff 14529 (19 files), git show 24505206 for the fold and gate, gh pr view 14529 --json statusCheckRollup (all hosted Rust lanes and Ripr Rust Small Result SUCCESS), all review threads resolved.

Limits: I did not rebuild or rerun the 44 tests; the hosted lanes are the affirmative evidence. The real-code survey and the agent-eval scenario are the author's measurements.

@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Nov 14, 2026
…-9xace9

# Conflicts:
#	crates/ripr/src/analysis/classify/infection.rs

Copy link
Copy Markdown
Member Author

Queue recovery diagnosis for unchanged head 24505206c6f80375c873d541bdc9720f7db415fe: the native timeline records removal at 2026-11-14 02:21:55 UTC, and the current PR reports mergeable=false, mergeable_state=dirty. The prior green qualification is an old-integration receipt, not qualification of a repaired merge.

I compared against main 688484fedfe4fbde08de396eed8e9acc8feae909, merge base bb5040a05cf4c3f3ac422eade17ed1c8c4912219. A read-only git merge-file -p probe using fetched base/head/main file contents isolates a conflict in crates/ripr/src/analysis/classify/infection.rs: this candidate's range-bound helper block (range_bound_infection, range_bound_change, aligned_range_texts, full_arm_line, range_consumer) competes at the same insertion point with the appended-string-arm helper block (added_string_arm_input and its helpers) landed by #14393 for #14388, commit a040a1e6d10263a18d98fb998ee78d292ea99b4f. The other overlapping paths, .ripr/traceability.toml, analysis/test_grip_evidence.rs, and SPEC-0001, merge clean in that textual probe.

Recovery belongs to the existing candidate owner: reconcile both helper families and their call sites without dropping either acceptance, then validate range-bound regressions and appended-string-arm coverage together, obtain independent review bound to the repaired head/base, and refresh required qualification only after those checks. This was a textual conflict probe, not compilation or behavioral validation. No branch edits, reruns, requeue or protection changes performed.

@github-actions

Copy link
Copy Markdown
Contributor

merge-ready is set, but this PR conflicts with main (head 24505206), so GitHub creates no test-merge ref and no qualification run can start. Merge main into the branch and resolve the conflicts, then remove and re-apply merge-ready.

@EffortlessSteven EffortlessSteven left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

SOURCE_REVIEW_READY for head ac8c2ee

This head merges main into 2450520 to resolve a textual conflict with #14393: the range-bound helpers and the appended-string-arm helpers were inserted at the same point in infection.rs. An independent review of the merge confirmed that each side's diff is pure insertions with nothing dropped or duplicated. It also confirmed that the two branches live in different probe families, so neither can shadow the other. Local proof on this head is in the PR body. The earlier source review of 2450520 still applies to the range-bound change.


Generated by Claude Code

@EffortlessSteven EffortlessSteven left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

VERDICT: APPROVE ac8c2ee — no blocking findings on this head.

Reviewed head: ac8c2ee55ff1021b685592470122ad4628419dc5 (base a088ab40b9). This head is the previously approved 24505206 merged with origin/main; the change itself moved only by that merge.

What the movement touched

ac8c2ee5 is a merge whose first parent is 24505206; 24505206 is an ancestor, so nothing was rewritten. Diffing the two commits across the PR's own files shows exactly one change outside the merge: crates/ripr/src/analysis/classify/infection.rs gains 416 lines, all additions from main's multi-line predicate work (#14232). The range-bound change, its tests, the fixture, the spec section and the changelog fragment are byte-identical to the head I approved.

The added block is a different infection arm and does not touch range_bound_infection or the RangeChangeVisibility selection: at this head range_bound_infection still credits only ExactInputSeparates/InexactInputSeparates and otherwise emits the explicit "could not show that any related test's asserted input separates them" refusal (infection.rs:1142-1186).

Evidence

  • git diff --stat 24505206 ac8c2ee5 restricted to infection.rs, value_contradiction.rs, range_bound_edit.rs, extract/oracles/reach.rs shows one file, insertions only.
  • git diff --stat a088ab40b9 ac8c2ee5 shows the same 19-file PR surface as before the merge (infection, value contradiction, oracle reach, extract mod, spec, fixture, corpus row, integration test, changelog, traceability).

Limits

Source-level review only; no build or test run, and no host-qualified gate result is claimed here. This verdict keeps the evidence of the 24505206 review and adds only the merge-inspection above.

Copy link
Copy Markdown
Member Author

Recovery handoff for exact head ac8c2ee55ff1021b685592470122ad4628419dc5: required Ripr Rust Small Result, Rust gates, all four test shards and the shard verifier are now successful. All eight review threads are resolved; GitHub reports clean/mergeable. My independent conflict-resolution source check against previous head 24505206 and merged main a088ab40b9f7bfddbdbbcf66b580a666e44cf199 confirmed both range and appended-string-arm helper blocks remain byte-for-byte, with separate probe-family call paths. No material merge-resolution finding; no duplicate build run.

The native timeline still ends with removal at 2026-11-14 02:21:55 UTC and contains no re-admission after repair. The existing owner can now check current native queue membership and, if still absent and head unchanged, re-enqueue through the normal protected process. My native queue query is blocked by HTTP 403 unauthenticated rate limiting, and the connected API does not expose an explicit enqueue operation. I have not attempted a direct merge, substituted auto-merge, rerun CI, changed protections or requested a duplicate queue entry. This is a green qualification/recovery handoff, not a merge receipt.

@EffortlessSteven
EffortlessSteven added this pull request to the merge queue Nov 14, 2026

@EffortlessSteven EffortlessSteven left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

SOURCE_REVIEW_READY
VERDICT: APPROVE ac8c2ee

Reviewed head: ac8c2ee55ff1021b685592470122ad4628419dc5 (base a088ab40b9). This head is the previously approved 24505206 merged with origin/main; the change itself moved only by that merge.

What the movement touched

ac8c2ee5 is a merge whose first parent is 24505206; 24505206 is an ancestor, so nothing was rewritten. Diffing the two commits across the PR's own files shows exactly one change outside the merge: crates/ripr/src/analysis/classify/infection.rs gains 416 lines, all additions from main's multi-line predicate work (#14232). The range-bound change, its tests, the fixture, the spec section and the changelog fragment are byte-identical to the head I approved.

The added block is a different infection arm and does not touch range_bound_infection or the RangeChangeVisibility selection: at this head range_bound_infection still credits only ExactInputSeparates/InexactInputSeparates and otherwise emits the explicit "could not show that any related test's asserted input separates them" refusal (infection.rs:1142-1186).

Evidence

  • git diff --stat 24505206 ac8c2ee5 restricted to infection.rs, value_contradiction.rs, range_bound_edit.rs, extract/oracles/reach.rs shows one file, insertions only.
  • git diff --stat a088ab40b9 ac8c2ee5 shows the same 19-file PR surface as before the merge (infection, value contradiction, oracle reach, extract mod, spec, fixture, corpus row, integration test, changelog, traceability).

Limits

Source-level review only; no build or test run, and no host-qualified gate result is claimed here. This verdict keeps the evidence of the 24505206 review and adds only the merge-inspection above.

@EffortlessSteven
EffortlessSteven removed this pull request from the merge queue due to a manual request Nov 14, 2026
@EffortlessSteven
EffortlessSteven added this pull request to the merge queue Nov 14, 2026
@EffortlessSteven

Copy link
Copy Markdown
Member Author

Disposition: queue-head stall recovered — dequeued and re-enqueued at ac8c2ee5.

This PR carried merge-ready, had a current substantive APPROVE at ac8c2ee55ff1021b685592470122ad4628419dc5 (03:32Z, refreshed 09:03Z), zero unresolved review threads, all PR-level checks green, and merged cleanly with current main (git merge-tree exit 0 against 1d082a4632). It was not a waiting state.

The defect: it sat at native merge-queue position 1, state AWAITING_CHECKS, from 2026-11-14T03:53:03Z with no merge_group run ever created for its head — 16 hours. Position and head SHA were unchanged across two reads. That is a queue-head stall, not a merge_group run in progress.

Action: dequeued (isInMergeQueue false) and re-enqueued at 2026-11-14T20:12:31Z. The queue advanced immediately: #14630 is now position 1 and the stale UNMERGEABLE entry #14653 left the queue. No head change, no restack, no label change.

State machine: QUEUED_HEAD_STALLED → DEQUEUED → REENQUEUED. Guard: item 6 (an unmerged mergeable PR is a defect I own) plus the stall test (no merge_group run for 30+ min, position and head unchanged across two checks).

Copy link
Copy Markdown
Member Author

Evidence correction to the queue-stall disposition: this candidate did have an active native merge-group run before the dequeue. Run 43631015439 evaluated composed G 84bf1d232ba74ce4f65bc1bf2c89b6951379f531 (queue branch pr-14529-1d082a4632c9c0d10a769b4d814bc85070e55f1a), with successful admission job 132557592189. Group commits differ from PR heads; searching only H ac8c2ee5 does not establish absence of a group.

All four test shards and shard verifier passed; Rust gates 132557875381 also passed. The final Result 132574009448 failed at 20:14:09, after the 20:12:17 dequeue and 20:12:31 re-admission. Its environment records ADMISSION_STATUS: admitted, GITHUB_RESULT: success, GITHUB_TESTS_RESULT: success, but ELIGIBILITY_RESULT: failure. This sequence does not support the claim that no group was created or that the item was not waiting on an in-progress group.

Please reconcile the recovery record and inspect native group identity/constituent mapping before applying the stall-recovery rule again. Preserve the new admission and active successor groups; no additional dequeue, rerun, label or source change is requested or performed here. Current owner retains recovery.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants