Skip to content

fix(clippy): inline format arg to un-red main (useless_borrows_in_formatting) - #413

Closed
byte-the-bot wants to merge 0 commit into
mainfrom
fix/clippy-useless-borrow-github-oauth
Closed

fix(clippy): inline format arg to un-red main (useless_borrows_in_formatting)#413
byte-the-bot wants to merge 0 commit into
mainfrom
fix/clippy-useless-borrow-github-oauth

Conversation

@byte-the-bot

Copy link
Copy Markdown
Collaborator

What

Clippy 1.97 (CI's toolchain) promoted/enforced useless_borrows_in_formatting and now flags the &oauth_response borrow inside the decode-error format! in github_oauth.rs. This makes main itself red, so every open coreyja.com PR inherits the failure (#378, #398, #412, #392 all show a failing Lint check they didn't cause).

Fix

Inline the format argument:

format!("...: {oauth_response:?}")

This drops the redundant borrow (satisfies clippy 1.97) and is also inlined (satisfies clippy 1.95, which wants uninlined_format_args) — robust across the toolchain drift. Verified cargo clippy -p server --all-targets and cargo fmt --check clean locally.

Why standalone

One-line, zero-risk fix that un-reds main and unblocks the whole PR queue at once, rather than folding it into any single feature PR.

🤖 Generated with Claude Code

@byte-the-bot

Copy link
Copy Markdown
Collaborator Author

This PR is now empty — nothing left to merge.

I rebased it onto current main today and it came out at zero commits ahead, zero files changed:

$ git diff --stat origin/main origin/fix/clippy-useless-borrow-github-oauth
$ git rev-list --count origin/main..origin/fix/clippy-useless-borrow-github-oauth
0

The useless_borrows_in_formatting fix landed on main independently while this sat. Main is green (c6fdfdf), so it isn't red and this isn't un-redding anything.

Safe to close. I didn't close it myself since that's your call — say the word, or just hit close.

Second one of these today: coreyja-studio/bake#33 is in the same category (its lint stopped firing on its own under floating toolchain: stable), though that one at least still has a real diff.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant