Skip to content

fix(check): lead a missing --base with a spelling check when no remote exists - #8519

Merged
EffortlessSteven merged 1 commit into
mainfrom
claude/project-thread-yhseju
Oct 17, 2026
Merged

EffortlessSteven merged 1 commit into
mainfrom
claude/project-thread-yhseju

Conversation

@EffortlessSteven

@EffortlessSteven EffortlessSteven commented Oct 17, 2026 •

Copy link
Copy Markdown
Member

Requested by Steven · project thread

Before: ripr check --base bad-ref in a repo with no remote said only "No git remote is configured: add the remote hosting bad-ref ... then fetch it", sending a typo straight to git remote add.

After: the same error first says to check the spelling of bad-ref (and points at git branch --list), then keeps the add-remote step for refs that live on a remote.

How: one message change in missing_ref_repair (crates/ripr/src/analysis/diff/load.rs); the existing no-remote unit test now also asserts the spelling hint. The old substrings the smoke/hostile tests match are kept. Found by a new-user walkthrough of check/doctor.

Verified: cargo xtask precommit policy checks pass. Not verified locally: the lib test compile was OOM-killed on the shared box, so hosted CI is the proof for missing_ref_repair.


Governing issue or accepted claim: #7653 — partial: this lands the no-remote advice arm only (spelling-first message with add-remote fallback kept); the with-remote beyond-history ancestor arm stays open on that issue.

Acceptance delta (one sentence): In a repository with no remote, the ripr check --base <unresolvable-ref> error now leads with a spelling check naming the ref and still gives the add-remote step, asserted by the extended missing_ref_repair_names_the_add_remote_step_when_no_remote_exists unit test.


Generated by Claude Code

…e exists

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018e1icNGoyApXPrHyi95UVv
@gemini-code-assist

Copy link
Copy Markdown

Warning

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

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

coderabbitai Bot commented Oct 17, 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 49 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 76 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
  • Configuration used: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Essentials
  • Run ID: a8b3dfe8-d269-41dd-9849-79358b0f6d9d
📥 Commits

Reviewing files that changed from the base of the PR and between 3fc24df and 0b0f7d9.

📒 Files selected for processing: 1
  • crates/ripr/src/analysis/diff/load.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 17, 2026 17:42
@gemini-code-assist

Copy link
Copy Markdown

Warning

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

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Decision

  • Needs one verification check before upstream.

Verification questions

  • Confirm author's claim 'the smoke/hostile tests match old substrings' is asserted but only one in-repo test (no_remote_paths) is visible in the diff; smoke/hostile hosts are not part of this PR. Verify in CI those older substring checks still pass to avoid silent regression.

Refuted

  • Spelling hint leads --base <bad-ref> in a no-remote repo away from git remote add; add-remote wording is preserved as a conditional fallback.
  • Allocation-failure / native UB concern for the new format! call.; refuted because: This is a pure string format! with two &str/owned-ref pieces on the no-remote branch; no native/unsafe path touched and allocation failure is not raised by the diff, seeded thread, or any candidate.
  • The new spelling hint could send users to git branch --list even when the ref is expected to live on a remote (typo of an existing remote branch).; refuted because: The reworded message places the spelling sentence first but preserves the add-remote/fetch instruction in the same paragraph, so the remote path is still suggested.
  • The spelling hint duplicates logic that should live in a shared helper used across missing_ref_repair arms.; refuted because: Only the Some([]) arm needs the spelling hint; single-remote and multi-remote arms give concrete fetch/add commands that already disambiguate the ref. Extracting a helper would have a single caller and would not reduce duplication.

Evidence gaps

  • Model proof intent was rejected by deterministic validation.
  • PR body says lib test compile was OOM-killed locally; hosted CI is the proof for the new assertion.

@EffortlessSteven

Copy link
Copy Markdown
Member Author

CI Step 26 Golden Contract Diagnostic: Inherited Golden Drift on \main\

In run 39054938926, all code checks, strict Clippy, and 17,038 unit/integration tests passed. Step 26 \Golden output contracts\ failed on 3 fixtures:

\\ ext
drift: fixture match_arm_tuple_terminal_generated_constructor [human.txt]: formatting_only (1 line(s))
drift: fixture match_arm_tuple_terminal_imported_formatter [human.txt]: formatting_only (1 line(s))
drift: fixture match_arm_tuple_terminal_inherited_constructor [human.txt]: formatting_only (1 line(s))
\\

Root Cause:
Commit \�1669187c\ (#8493) updated \crates/ripr/src/output/human.rs\ to append \ ({base_side} base-side evidence, not candidate edit targets)\ to \Summary:\ line 5. When PR #7836 (\5fbd018b1) subsequently landed introducing these three new fixtures, their expected \human.txt\ and \human-full.txt\ goldens were not updated with that phrase.

This failure is pre-existing on \main\ and unrelated to the spelling check changes in this PR. A small golden re-bless PR on \main\ will clear this gate.

@EffortlessSteven

Copy link
Copy Markdown
Member Author

CI Diagnosis (Run 39054938926)

@EffortlessSteven

Copy link
Copy Markdown
Member Author

Convergence pass: bouncing this PR to rerun the required gate on a repaired merge ref.

Why: The failing Ripr Rust Small Result (run 39054938926) failed only at Step 26 "Golden output contracts" with 6 formatting_only drift lines on the 3 match_arm_tuple_terminal_* fixtures — a failure inherited from main (the goldens predated #8493's Summary suffix; #7836 added the fixtures with stale goldens). Nothing in this PR's diff (1 message string + 1 test assertion in crates/ripr/src/analysis/diff/load.rs) touches renderer output. The repair already landed on main: #8524 (4229f8187) re-blessed exactly those fixtures to include the (N base-side evidence, not candidate edit targets) suffix matching human.rs:452, and main's hosted routed-rust run on d3d2d9c496 (run 39065476620) is green. The old merge ref predates that fix, so this PR's qualification needs one fresh ready_for_review run.

Evidence from the previous run (already on record):

  • All 17,038 tests passed in run 39054938926, including the modified test missing_ref_repair_names_the_add_remote_step_when_no_remote_exists (PASS 17:54:54Z) — closes the review's evidence gap about the local OOM.
  • Old substrings the smoke/hostile hosts match are kept: crates/ripr/tests/cli_smoke.rs:29804 and crates/ripr/tests/hostile_repos.rs:1041 both match on contains, and the new message retains No git remote is configured and git remote add.
  • Local reproduction on the current merge ref (main 0b443d840 + this head, no conflicts per git merge-tree): cargo xtask goldens check passes (exit 0).

Closing and reopening, then Draft -> Ready, per the stale-merge-ref refresh route.

@EffortlessSteven
EffortlessSteven marked this pull request as draft October 17, 2026 21:20
@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 17, 2026 21:20
@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 marked this pull request as draft October 17, 2026 21:35
@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 17, 2026 21:35
@gemini-code-assist

Copy link
Copy Markdown

Warning

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

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Decision

  • Needs reviewer attention before upstream: findings remain.

Confirmed findings

  • Author reported local lib test compile OOM-killed; convergence run 39054938926 reports all 17,038 tests passing including the modified assertion. No local repro path on this lane.

Verification questions

  • Confirm old substrings used by smoke/hostile tests (No git remote is configured, git remote add) remain present in the new string.
  • Confirm only one in-repo test (no_remote_paths) is touched; PR claims smoke/hostile hosts also match old substrings but neither is in this diff.
  • Confirm modified assertion adds two substring checks plus the old git remote add check, all positive. No negative assertion that the spelling hint is absent when a remote exists.
  • Confirm author's local OOM claim is closed by hosted CI passing run 39054938926 (17,038 tests PASS including the modified missing_ref_repair_names_the_add_remote_step_when_no_remote_exists); however the smoke/hostile substring claim remains unverified in this PR's diff scope and should be re-confirmed in CI output.

Refuted

  • The new spell-check message is a pure string format! with a single owned-ref insert; no native/unsafe surface.
  • Spelling hint sends users to git branch --list even when ref is expected to live on a remote (typo of an existing remote branch).; refuted because: The reworded paragraph places the spelling sentence first but keeps the conditional 'if it lives on a remote, add that remote ... then fetch it' sentence; remote-path guidance still appears in the same output.
  • spelling hint and add-remote step should be split into two messages or extracted into a shared helper; refuted because: the no-remote branch is the single consumer and the conditional add-remote instruction must remain co-located with the spelling nudge so the remote path is still surfaced; extraction would be over-engineering for one call site.
  • Allocation-failure / native UB concern for the new format! call; refuted because: the change is a single format! expansion of two &str pieces on the no-remote branch; no unsafe, no allocation-failure path introduced, and the seeded thread plus prior review summary already refuted this on identical grounds.

Parked follow-ups

  • Opposition parked follow-up: PR body claims 'the smoke/hostile tests match old substrings are kept' but no smoke/hostile fixture lives in this PR's diff. If a downstream hostile harness expects the literal 'No git remote is configured: add the remote hosting' prefix, the punctuation change at line 1338 silently mutates the matched substring.

Evidence gaps

  • Model proof intent was rejected by deterministic validation.

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