Skip to content

Chore: fix clippy warnings for stable (1.87) and nightly (1.89) #1504

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 9, 2025

Conversation

photovoltex
Copy link
Member

Fixes the current clippy warnings and upcoming clippy warnings ( up until 1.79, aka current nightly). The fixes where applied automatically by clippy with the following commands.

cargo clippy --workspace --all-features --allow-dirty --fix
cargo +nightly clippy --workspace --all-features --allow-dirty --fix

@photovoltex photovoltex requested review from roderickvd, kingosticks and Copilot and removed request for Copilot May 28, 2025 12:02
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR runs automatic cargo clippy --fix on stable (1.87) and nightly (1.89) to silence current and upcoming lints.

  • Migrated explicit format!("…{}", var) and write!(…, "{}", var) calls to inline {var} syntax
  • Replaced io::Error::new usages with the io::Error::other helper
  • Simplified numeric expressions (e.g., removed redundant -1.0 *)

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/main.rs Updated format strings to use inline {DISABLE_DISCOVERY} syntax
playback/src/mixer/mappings.rs Simplified f64::powf call by removing redundant multiplication
oauth/src/lib.rs Switched println! to inline {auth_url} interpolation
discovery/src/lib.rs Updated error messages to use inline {name}/{error}
core/src/proxytunnel.rs Replaced io::Error::new with io::Error::other and simplified map_err
core/src/mercury/types.rs Changed write!(f, "{}", s) to write!(f, "{s}")

@photovoltex photovoltex merged commit 3686718 into librespot-org:dev Jun 9, 2025
13 checks passed
@photovoltex photovoltex deleted the fix-clippy branch June 9, 2025 10:13
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