Repository navigation
fix(cli): unblock Rust 1.95 Clippy on ripr plus - #2591
EffortlessSteven wants to merge 1 commit into
Conversation
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning Review limit reached
Next review available in: 18 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
There was a problem hiding this comment.
Decision
- Needs reviewer attention before upstream: findings remain.
Confirmed findings
- clippy::literal_format_with_no_arguments trigger likely indicates Rust 1.95 tightened detection; rewrite to .to_string() is the standard, minimal fix and matches PR body claim of source-preserving one-line fix.
- No blocker/medium actionable issue isolated to right-side diff lines. Source-route scope check is bounded to ripr_plus.rs; sibling
format!()sites in the same file or adjacentriprCLI modules were not receipted-scanned. Treat as residual coverage gap, not a finding. - Error string could be a const &str or a thiserror variant for consistency with the rest of the crate's error style, but extraction is out of scope for a Clippy unblock.
Verification questions
- Confirm diff is local to
parse_optionserror construction; replacesformat!(const_str)withconst_str.to_string(). Publicparse_optionssignature unchanged, so this is a no-op for callers. - Confirm test oracle is non-discriminating for the
parse_optionschange incrates/ripr/src/app/ripr_plus.rs. - Confirm ref #2587 is referenced as the proximate cause, but no diff or link to #2587 is provided in this packet to confirm the Clippy trigger was the literal
format!macro on a constant string. Reasonably inferred (Rust 1.95 clippy::unnecessary_format or similar), but not strictly evidenced in-packet.
Refuted
- Possibly allocation-failure regression from format! → .to_string(); refuted because: No PR diff, seeded thread, or candidate raises allocation-failure analysis; literal was &'static str so no new heap allocation is introduced vs. prior format!.
- Tests must distinguish old format! behavior from new .to_string() behavior; refuted because: Both produce identical String; no observable behavior delta exists to test. Lint is a compile-time constraint, not runtime semantics.
- Allocation failure in
.to_string()could panic whereformat!previously propagated cleanly; refuted because: Both paths allocate on the heap;.to_string()on a&'static stris equivalent in failure mode (abort on OOM). No behavioral regression. - Refutation attempt: 'exact user-facing error text and behavior' assertion — substituting
format!()with.to_string()on a plain&strliteral is byte-equivalent (no fmt args), so behavior preservation is sound. - Opposition attempted to find a regression path: no other call sites of
format!were touched, the Err return type is stillResult<_, String>, and the message is constructed unconditionally once before return.
Parked follow-ups
Evidence gaps
[review body truncated; see review artifacts]
Summary
Unblock current
mainafter the merged #2587 CLI error update exposed a Rust1.95 Clippy failure in the unchanged
ripr plusparser path.format!with the equivalent owned string.Refs #2587
Acceptance matrix
cargo clippy -p ripr --lib --all-features -- -D warningsripr plusmissing-input error remains unchangedProof
cargo fmt --all -- --checkcargo clippy -p ripr --lib --all-features -- -D warningsgit diff --checkThis is a mainline unblock; it does not change the
ripr pluscontract.