Skip to content

fix(rust): import-path affinity for an impl owner must name its type (#16523) - #16557

Open
EffortlessSteven wants to merge 8 commits into
mainfrom
claude/project-thread-xgnffs
Open

EffortlessSteven wants to merge 8 commits into
mainfrom
claude/project-thread-xgnffs

Conversation

@EffortlessSteven

@EffortlessSteven EffortlessSteven commented Nov 29, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Import-path affinity for an owner inside an impl now requires the test line that spells ::<name> to also name the owner's self type or trait. A bare ::new related Alpha::new to every test that calls any X::new(..).
  • Owners outside an impl keep the existing module-path rule.
  • The pool_relation reference answer now derives from the unscoped relation, filtered to the pool, so the pool routes and the package shortcut stay out of their own oracle (review suggestion carried from perf(review): decide second-stage pool relations without resolving every test (#12940) #16096).

Swarm / Source Boundary

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

Source-of-truth Links

Governing issue or accepted claim: #16523 (split from #12940)
Acceptance delta (one sentence): an associated owner is related by import-path affinity only to tests whose ::<name> line names its type or trait.

Candidate Relationships

Candidate branch: claude/project-thread-xgnffs
Stack parent or prerequisite PR: none (#16096 is on main)
No equivalent open PR found (searched open PRs for #16523 and the matcher name).

Scope

  • crates/ripr/src/analysis/test_grip_evidence/related_tests.rs: OwnerContext::associated_path_qualifiers, test_names_associated_owner_compact, one branch in match_import_path_affinity.
  • Tests: new tests/associated_import_affinity.rs; reference helper in tests/pool_relation.rs.
  • Changelog entry.

Scope Classification

  • One production behavior

Design notes

  • The rule is line-level, like the one it narrows: the line holding ::<name> must contain the type or trait as a whole identifier. Alpha::<T>::new, module::Alpha::new, <Alpha as Build>::build and Build::build relate. Other::new(Alpha::default()) still relates (same line names the type).
  • A use line no longer counts for an associated owner: use cannot import an associated function.
  • Self::<name> is not accepted: a #[test] function is never inside an impl.
  • Named limitation: a call through a renamed import (use a::Alpha as Z; Z::new()) or a path split across lines is not read as naming the type. Corpus count for this shape: none observed (no golden, verdict-corpus or honesty-corpus output changed); I did not count it on a wider repository.

Proof (run on b0af2a4db, the head)

  • Unit: cargo test -p ripr --lib --no-default-features --features lang-python,lang-rust -- seam_cache first_useful_action test_grip_evidence::tests:: 1,017 passed, 0 failed (includes the generation pins and the new module). Reduced features are the only lib-test build that links in this 15 GB container; hosted shards are the full run.
  • cargo test -p ripr --test cli_smoke: 914 passed. --test lsp_lifecycle gap_corpus: 21 passed. cargo test -p xtask rust_corpus_projection: 5 passed.
  • cargo clippy -p ripr --all-targets -- -D warnings and cargo clippy -p xtask --all-targets -- -D warnings: exit 0.
  • cargo xtask goldens check: exit 0, no drift. check-fixture-contracts, check-output-contracts, check-doc-artifacts: pass.
  • cargo xtask verdict-corpus check-all: exit 0, 4 corpora (run on 4a932a1a2, before the generation commits; no analysis source changed after it).
  • cargo xtask check-evidence-promotion-honesty: pass before the bump with no report change, and pass after it.
  • Replay on the ripr review-comments times out on a large-workspace diff that edits tests related to thousands of seams (typed limited_timeout, no guidance; was: refuse at 1200 files / OOM) #12940 diff (review-comments, base 52844de5, head 7cf9cd6d, release build of 4a932a1a2, 4 workers, default 600 s):
binary narrowing seams kept for the second stage outcome
main with #16096 (5994aa08f) 370 s 4,803 of 45,207 exit 2, limited_timeout, no second-stage window completed
this change (4a932a1a2) 368 s 4,484 of 45,207 exit 2, limited_timeout, no second-stage window completed

The change removes 319 seams from the second stage on this diff. It does not make the command finish, and it does not measurably speed up the second-stage windows that ran (20 seams in 118 s wall against 24 in 170 s; single runs, different seam sets). No completion claim.

Cache generation

Claimed 1.233 / 0.235 on the #16466 map (comment 7249863499); 1.230 to 1.232 are held by #16447, #16162 and #16143. Related-test sets change on real repositories, so entries cached by an older binary must not be reused. No committed finding changed: the 61 recaptured honesty reports differ only in their artifact, source_subject and analysis_inputs metadata lines, and the boundary_gap unchanged-attempt snapshots move to 1.233 with recomputed content commitments and receipt hashes (algorithm checked against the committed 1.229 state before use).

Not established

https://claude.ai/code/session_01SvmPmmv8ne82Ko6vufDhTN


Generated by Claude Code

…16523)

A bare `::name` related an associated function to every test calling any
`X::name(..)`; an owner named `new` related to about 7,000 tests. The line
that spells `::name` must now name the owner's self type or trait, or
`Self` in the owner's file. Owners outside an impl keep the module-path
rule. The pool-relation reference now derives from the unscoped relation.

Unit proof pending: first local run in progress at commit time.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SvmPmmv8ne82Ko6vufDhTN
… affinity (#16523)

A #[test] function is never inside an impl, so Self::name cannot name the
owner from a test body.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SvmPmmv8ne82Ko6vufDhTN
@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!

@coderabbitai

coderabbitai Bot commented Nov 29, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

  • Ask an admin to enable usage-based reviews

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Next included review available in 5 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 138 included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Essentials
  • Run ID: 5484e30a-696a-458d-9b09-c6962a6a8975
Commits

Reviewing files that changed from the base of the PR and between af1880e and cea9e89.

Files selected for processing: 78

  • .ripr/traceability.d/16523-associated-import-affinity.toml
  • changelog.d/16523-associated-import-affinity.md
  • crates/ripr/src/analysis/seam_cache.rs
  • crates/ripr/src/analysis/test_grip_evidence/related_tests.rs
  • crates/ripr/src/analysis/test_grip_evidence/tests.rs
  • crates/ripr/src/analysis/test_grip_evidence/tests/associated_import_affinity.rs
  • crates/ripr/src/analysis/test_grip_evidence/tests/pool_relation.rs
  • crates/ripr/tests/lsp_lifecycle/gap_corpus_currentness.rs
  • docs/OUTPUT_SCHEMA.md
  • fixtures/boundary_gap/expected/CHANGELOG.md
  • fixtures/boundary_gap/expected/first-useful-action/unchanged-after-attempt/after.repo-exposure.json
  • fixtures/boundary_gap/expected/first-useful-action/unchanged-after-attempt/agent-receipt.json
  • fixtures/boundary_gap/expected/first-useful-action/unchanged-after-attempt/agent-verify.json
  • fixtures/boundary_gap/expected/first-useful-action/unchanged-after-attempt/before.repo-exposure.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-field-snapshot-missing-expected.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-field-snapshot-wrong-receiver.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-async-fn-activated-unsupported.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-async-fn-entry.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-async-fn-intermediate.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-async-fn-last-hop.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-async-fn-method-entry.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-async-fn-method-last-hop.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-async-fn-operand.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-async-operand-helper.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-async-operand.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-dormant-body.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-foreign-helper.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-free-helper-identity.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-helper-scope-shadow.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-helper-type-parameter.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-local-wrapper.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-macro-discard.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-inherent-receiver-module-type-shadow.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-adapter-fed-error.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-bool-local-compared-with-true.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-branch-local-else-only.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-branch-local-rebound-let.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-field-snapshot-exact.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-field-snapshot-inline.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-field-snapshot-literal.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-field-snapshot-other.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-field-snapshot-settings.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-field-snapshot-weak.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-file-module-nested-block-renamed-other-function-outer-call-control.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-file-module-nested-block-renamed-other-function.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-guarded-boundary-guard-missing.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-guarded-statement-boundaries.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-integration-test-nested-block-renamed-other-function-sibling-mount-control.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-integration-test-nested-block-renamed-other-function.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-late-assert-eq-definition-match-arms.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-lib-test-false-skipped.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-local-binder-named-like-other-function.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-local-binder-named-like-owner-block-control.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-local-closure-named-like-owner-map.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-macro-held-owner-call.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-macro-held-owner-result-local.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-manifest-rebound-assertion-root.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-matches-compared-with-true.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-matches-or-pattern-of-values.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-matches-or-pattern-single-value-control.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-nested-block-renamed-other-function-outer-call-control.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-nested-block-renamed-other-function.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-ok-assertion-failure-seam.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-panic-marker-collision.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-panic-marker-neutral.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-proximity-other-function.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-rebound-assert-eq-match-arms.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-rebound-read-macro-unselected-arm.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-renamed-other-function-qualified-control.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-renamed-other-function.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-same-named-call-kinds.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-test-local-rival-bare-use.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-test-local-rival-glob-use.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-tuple-rebound-owner-unselected-arm.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-unselected-match-arm.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-repo-exposure-wrapper-fed-error.json
  • fixtures/evidence-promotion-honesty-corpus/reports/rust-test-local-rival-import-control.json
  • xtask/src/tests/rust_corpus_projection.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

…ffinity (#16523)

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SvmPmmv8ne82Ko6vufDhTN
…ts at generation 1.233 (#16523)

61 honesty reports recaptured with the analyzer at cf253b0; only capture
metadata lines change. The boundary_gap unchanged-attempt snapshots move to
1.233 with recomputed content commitments and receipt hashes.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SvmPmmv8ne82Ko6vufDhTN
@EffortlessSteven
EffortlessSteven marked this pull request as ready for review November 29, 2026 04:00
@EffortlessSteven EffortlessSteven self-assigned this Nov 29, 2026
@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 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

Independent source review of exact head b0af2a4 against current main (75 files, +376/-205). I did not author this PR. This is a source and oracle review by reading; I did not build or run this head, and hosted qualification has not run on it.

Read in full: the production diff in test_grip_evidence/related_tests.rs; impl_self_type_name, owner_trait_name and compact_impl_type_name's documented contract in classify/related_tests.rs; relation_establishes_reach cases for this reason; the new tests/associated_import_affinity.rs; the changed reference helper in tests/pool_relation.rs; the three cache generation constants and their pins in seam_cache.rs; the changelog entry. The 61 honesty reports and the boundary_gap snapshots I read by file inventory and sample only, not line by line.

Claims checked

  1. The narrowed rule only applies where a type is known. associated_path_qualifiers returns a value only when impl_type is set, which comes from an ::impl segment in the owner id with generics, references and path prefixes stripped. A free owner, a self type that has no compact name, and a non-Rust owner all keep the existing reader. So the change cannot remove a relation from an owner whose type the rule could not spell.
  2. One producer. match_import_path_affinity is the only producer of this reason for Rust seams, and it serves the full and the compact evidence paths, so there is no second copy to drift.
  3. Direction. This reason does not establish reach (relation_establishes_reach refuses it for function and module owners). Removing it can lower a weak relation and can never grant credit. The retained-line predicate is unchanged: the new reader requires ::name, which implies the :: the retention filter keeps.
  4. Attack point 1, another implementor or a generic. Beta::build() for an owner impl Build for Alpha::build is dropped, which is right: it does not run this owner. Build::build and <Alpha as Build>::build stay. T::build() in a generic helper is dropped with no type on the line; that test keeps any stronger relation, and this one never carried reach.
  5. Attack point 2, the use branch. Correct to drop for an associated owner: use cannot bring an associated function into scope, so a use line with a matching last segment names a module or a free item of that name.
  6. Attack point 3, aliases. A renamed import and a path split across lines are lost. Both are named in the changelog and in the function's comment. Their frequency is not measured; the PR says so.
  7. Attack point 4, generations. Full 1.229 to 1.233, sharded and compact 0.231 to 0.235, each with its pin and the xtask corpus constant moved together. Related sets change on real repositories, so a bump is required. I did not recompute the boundary_gap commitments; the hosted fixture and output contract gates decide that.

Oracle grip. By reading the rule on main: other_type (Beta::new) contains ::new and inline_use has a use line whose token is new, so both related before and the first new test fails there. The positives sit in the same test file as the negatives, so the file is indexed when the assertion passes. The pool_relation reference now comes from the unscoped relation, which removes the shared-shortcut weakness I raised on #16096.

Non-blocking suggestions

  • Assert the fixture's test count (eight) before the relation claims, so a negative cannot pass because one test stopped being indexed.
  • Add the two shapes the rule is meant to keep but the fixture does not hold: Alpha::build (type path to the trait method) and an owner in a generic impl (impl<T> Wrap<T>), which exercises the stripped self type.
  • A trait's default method body has no ::impl segment, so it keeps the bare ::name rule. Worth one line in the limitation list.

Missing evidence, recorded as missing: hosted qualification on this head; cargo xtask precommit; the related-test count for one new owner before and after (acceptance item on #16523, the author reports the kept-seam count 4,803 to 4,484 instead); CodeRabbit and Gemini are quota-limited, which is absent review.

Public claim. The changelog states the rule and its alias limitation and makes no speed or completion claim, which matches the replay in the PR body.


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.

SOURCE_REVIEW_READY

This replaces review 6101335236 on the same head, whose wording tripped the admission parser; the content is otherwise the same.

Independent source review of exact head b0af2a4 against current main (75 files, +376/-205). I did not author this PR. This is a source and oracle review by reading; I did not build or run this head, and hosted qualification has not run on it.

Read in full: the production diff in test_grip_evidence/related_tests.rs; impl_self_type_name, owner_trait_name and compact_impl_type_name's documented contract in classify/related_tests.rs; relation_establishes_reach cases for this reason; the new tests/associated_import_affinity.rs; the changed reference helper in tests/pool_relation.rs; the three cache generation constants and their pins in seam_cache.rs; the changelog entry. The 61 honesty reports and the boundary_gap snapshots I read by file inventory and sample only, not line by line.

Claims checked

  1. The narrowed rule only applies where a type is known. associated_path_qualifiers returns a value only when impl_type is set, which comes from an ::impl segment in the owner id with generics, references and path prefixes stripped. A free owner, a self type that has no compact name, and a non-Rust owner all keep the existing reader. So the change cannot remove a relation from an owner whose type the rule could not spell.
  2. One producer. match_import_path_affinity is the only producer of this reason for Rust seams, and it serves the full and the compact evidence paths, so there is no second copy to drift.
  3. Direction. This reason does not establish reach (relation_establishes_reach refuses it for function and module owners). Removing it can lower a weak relation and can never grant credit. The retained-line predicate is unchanged: the new reader requires ::name, which implies the :: the retention filter keeps.
  4. Attack point 1, another implementor or a generic. Beta::build() for an owner impl Build for Alpha::build is dropped, which is right: it does not run this owner. Build::build and <Alpha as Build>::build stay. T::build() in a generic helper is dropped with no type on the line; that test keeps any stronger relation, and this one never carried reach.
  5. Attack point 2, the use branch. Correct to drop for an associated owner: use cannot bring an associated function into scope, so a use line with a matching last segment names a module or a free item of that name.
  6. Attack point 3, aliases. A renamed import and a path split across lines are lost. Both are named in the changelog and in the function's comment. Their frequency is not measured; the PR says so.
  7. Attack point 4, generations. Full 1.229 to 1.233, sharded and compact 0.231 to 0.235, each with its pin and the xtask corpus constant moved together. Related sets change on real repositories, so a bump is required. I did not recompute the boundary_gap commitments; the hosted fixture and output contract gates decide that.

Oracle grip. By reading the rule on main: other_type (Beta::new) contains ::new and inline_use has a use line whose token is new, so both related before, and the first new test asserts a list main does not produce. The positives sit in the same test file as the negatives, so the file is indexed when the assertion passes. The pool_relation reference now comes from the unscoped relation, which removes the shared-shortcut weakness I raised on #16096.

Non-blocking suggestions

  • Assert the fixture's test count (eight) before the relation claims, so a negative cannot pass because one test stopped being indexed.
  • Add the two shapes the rule is meant to keep but the fixture does not hold: Alpha::build (type path to the trait method) and an owner in a generic impl (impl<T> Wrap<T>), which exercises the stripped self type.
  • A trait's default method body has no ::impl segment, so it keeps the bare ::name rule. Worth one line in the limitation list.

Missing evidence, recorded as missing: hosted qualification on this head; cargo xtask precommit; the related-test count for one new owner before and after (acceptance item on #16523, the author reports the kept-seam count 4,803 to 4,484 instead); CodeRabbit and Gemini are quota-limited, which is absent review.

Public claim. The changelog states the rule and its alias limitation and makes no speed or completion claim, which matches the replay in the PR body.


Generated by Claude Code

@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 4 potential issues.

Devin Review

…import affinity (#16523)

Review repairs on #16557. A grouped import such as
use crate::{types::Alpha, support::new} paired a type with an unrelated
::new on one line; use items are now removed before the line is read. A raw
type name (r#gen) is compared by its name, as the line scan splits on #.
Tests gain the indexed-count precondition, the type path to a trait method,
a generic impl owner, and both negatives. Traceability under RIPR-SPEC-0005.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SvmPmmv8ne82Ko6vufDhTN

@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

Independent source review of exact head 51c0543. I did not author this PR. My review 6101335771 covered b0af2a4; this pass covers the one commit added since (three files, +110/-15) and keeps the earlier inspection for everything it did not touch. Read-only; I did not build or run this head, and hosted qualification has not run on it.

Read in full: the delta in test_grip_evidence/related_tests.rs (associated_path_qualifiers, test_names_associated_owner_compact, without_use_items, use_item_start), the delta in tests/associated_import_affinity.rs, and the new traceability file.

Delta claims checked

  1. A use item is not read. without_use_items removes each span from a word-initial use through the next ;, or to the end of the line when there is none. The word check keeps reuse and cause in place. Offsets are taken from ASCII matches, so the slices stay on character boundaries. Code after the item on the same line is kept, so use crate::types::Alpha; let a = Alpha::new(1); still relates through the call. The only text this can wrongly drop is a macro argument that spells use as a word, and that lowers a relation that carries no reach.
  2. A raw type name matches. Qualifiers drop the r# prefix, and the line scan already yields gen from r#gen because it splits on #. A bare gen::make cannot name a different item, since the raw form exists only because the plain word is reserved.
  3. The limitation list now names the trait default method case in the function comment.

Oracle grip. The fixture asserts 14 indexed tests before any relation is read, so each negative depends on a test that exists. grouped_use is the Devin case and is absent from the inherent owner's list; type_to_trait_method, generic_impl and raw_type are kept shapes with their own negatives (other_pick, other_make). Each list is compared whole, so an extra or a missing relation shows.

Review state. Unresolved threads: 0, read through the review-threads endpoint. The author reports four Devin threads answered and resolved, one declined with a reason; I read the code for the two repairs and agree both findings were real.

Missing evidence, recorded as missing: hosted qualification on this head; cargo xtask precommit; the before and after related-test count for one new owner; CodeRabbit and Gemini are quota-limited, which is absent review.


Generated by Claude Code

Copy link
Copy Markdown
Member Author

Rust gates failed on 51c0543e in check-evidence-promotion-honesty, and the cause is the integration basis, not the source: the job checks the merge with main, and two honesty reports that landed on main after this branch was cut (rust-repo-exposure-guarded-statement-boundaries.json, rust-test-local-rival-import-control.json) record cache schema 1.229 while this PR moves the analyzer to 1.233.

Repair on head cea9e894: merged main (2e58ff77c, no conflict) and recaptured those two reports with the merged analyzer; only their artifact, source_subject and analysis_inputs lines change. On that head locally: check-evidence-promotion-honesty pass, goldens check exit 0, check-fixture-contracts pass. merge-ready removed until a non-author review is on the new head.


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.

SOURCE_REVIEW_READY

Independent source review of exact head cea9e89. I did not author this PR. Reviews 6101335771 and 6101417498 covered the source through 51c0543; this pass covers what was added since and keeps that inspection. Read-only; no build or run on this head, and hosted qualification has not run on it.

What is new since 51c0543

  1. Merge commit 2e58ff7, parents 51c0543 and main af1880e. Across the merge, test_grip_evidence/related_tests.rs, the test module, seam_cache.rs and classify/related_tests.rs are byte-identical to 51c0543, so main did not touch the code this PR changes and the earlier source review still describes the head.
  2. Commit cea9e89 recaptures two honesty reports that reached main at generation 1.229 (rust-repo-exposure-guarded-statement-boundaries.json, rust-test-local-rival-import-control.json). Each changes exactly three lines: artifact, source_subject, analysis_inputs. Inside artifact only generated_at and content_sha256 differ; source_subject moves cache_schema_version to 1.233 with the same files_content_hash; analysis_inputs records the new analyzer revision. No finding line changed in either file.

Checked on the tree. No file under fixtures/ still records generation 1.229 at this head; 63 record 1.233. That is the condition the hosted honesty check refused on the previous head.

Why the previous head went red. The hosted job evaluates the merge with main, and the two reports arrived there after this branch was cut. That is an integration effect of the generation bump, repaired in the same candidate, not a defect in the relation change.

Missing evidence, recorded as missing: hosted qualification on this head, including the honesty check that refused before; cargo xtask precommit; the before and after related-test count for one new owner; CodeRabbit and Gemini are quota-limited, which is absent review. If another report lands on main at an older generation before this merges, the same refusal will recur in the queue run.


Generated by Claude Code

@github-actions

Copy link
Copy Markdown
Contributor

merge-ready is set, but this PR conflicts with main (head cea9e894), so GitHub creates no test-merge ref and no qualification run can start. 1. Merge main into the branch and resolve the conflicts. 2. Remove and re-apply merge-ready to request admission and qualification only. 3. After qualification is green, enqueue the PR through the native queue route; re-applying the label does not enqueue it.

@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.

REVIEW_READY for head cea9e89

Independent native-Windows review of fix(rust): import-path affinity for an impl owner must name its type (#16523) (PR #16557) at cea9e89 (merge-base af1880e is 5 commits behind main — current enough that no stale-base caveat is needed).

Source review (verified against source)

Delta (PR vs merge-base: test_grip_evidence/related_tests.rs +101, new tests/associated_import_affinity.rs +119, tests/pool_relation.rs +13, seam_cache.rs version bumps + comment/test updates, and small expectation updates across the repo-exposure fixture JSONs; no other production surface):

  • The narrowing is correct and well-reasoned: ::name alone names no type — every test that calls any X::new(..) spells ::new — so a bare associated-function path on the test line was overcrediting owners whose only tie was a same-named associated function. The line that spells ::name must now also name one of the owner's associated_path_qualifiers (the impl's self type, or the trait for a trait impl).

  • The three stated exclusions are each sound: a use item cannot import an associated function so its text is not read; a #[test] function is never inside an impl so Self::name cannot name the owner from a test body; raw identifiers (r#gen) are compared by name with the # split handled.

  • The rule stays line-level like the one it narrows (Other::new(Owner::default()) is read precisely as written), and the compact-test path (test_imports_owner_compact) is updated in the same commit, so lib and compact readers cannot disagree.

  • Generation-map hygiene is clean and lockstep: full CACHE_SCHEMA_VERSION 1.229 → 1.233, sharded 0.231 → 0.235, compact 0.231 → 0.235, all three in one commit with the claim comment naming the in-flight holders (1.230–1.232 per #16466). This PR's claim is exactly the next free pair, and the repo-exposure expectation updates are the expected blast radius of a classifier narrowing (previously overcredited fixtures lose the false credit, matching the renamed-other-function / same-named-call-kinds / rival-import controls).

  • Native proof (native Windows, worktree wt-16557 at head cea9e89): cargo test -p ripr --lib test_grip_evidence (exit 0, including the new associated_import_affinity module); cargo xtask goldens check (exit 0 apart from the known pre-existing python_parent_collected_test_shadow native-Windows fixture drift); cargo xtask check-evidence-promotion-honesty (exit 0); cargo xtask check-traceability (exit 0).

Scope and non-goals

  • Reviewed and proven at this head only; a later push restarts review.
  • The generation map on #16466 records this PR as holding 1.233/0.235 at this head; markers are head-exact and the writer rebases before merge per convention.
  • Merge mechanics belong to the writer; this review is evidence only.

Copy link
Copy Markdown
Member Author

For the existing owner’s next integration pass: once the conflict is resolved and GitHub advertises the fresh composition, the already-landed #15651 pre-label check is a fast way to catch a third stale report before requesting hosted qualification: cargo xtask check-evidence-promotion-honesty --pre-label 16557 main from a trusted checkout. Record its printed target, head and composed commit alongside the exact report recaptures. It deliberately refuses a stale merge ref, and a pass only verifies committed report metadata/pins on that composition; it does not replace the full honesty replay or fresh exact-head review. The current cea9e894 still conflicts, so there is no composed pass to carry forward.

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