Skip to content

fix: resolve clippy warnings across workspace - #1195

Open
DaleSeo wants to merge 2 commits into
mainfrom
fix/clippy-warnings
Open

fix: resolve clippy warnings across workspace#1195
DaleSeo wants to merge 2 commits into
mainfrom
fix/clippy-warnings

Conversation

@DaleSeo

@DaleSeo DaleSeo commented Aug 20, 2026

Copy link
Copy Markdown
Member

Motivation and Context

The PR resolves all the Clippy errors and warnings in the codebase.

How Has This Been Tested?

Breaking Changes

None.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update

Checklist

  • I have read the MCP Documentation
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have added or updated documentation as needed

@github-actions github-actions Bot added T-test Testing related changes T-core Core library changes T-examples Example code changes T-transport Transport layer changes labels Aug 20, 2026
@DaleSeo
DaleSeo marked this pull request as ready for review August 20, 2026 05:56
@DaleSeo
DaleSeo requested a review from a team as a code owner August 20, 2026 05:56
@DaleSeo DaleSeo self-assigned this Aug 20, 2026
@DaleSeo
DaleSeo force-pushed the fix/clippy-warnings branch from d513ed7 to 643c824 Compare August 20, 2026 06:04
@jamadeo

jamadeo commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Hey @DaleSeo what clippy config/version are you running with? The clippy step in CI runs with -D warnings, but it's passing.

--all-features enables the local feature, which cfg-gates out
tower.rs and most of the test suite, so the existing clippy step
never actually lints them.
@DaleSeo
DaleSeo force-pushed the fix/clippy-warnings branch from 643c824 to 7b4e093 Compare August 30, 2026 12:45
@github-actions github-actions Bot added T-CI Changes to CI/CD workflows and configuration T-config Configuration file changes labels Aug 30, 2026
@DaleSeo

DaleSeo commented Aug 31, 2026

Copy link
Copy Markdown
Member Author

@jamadeo Yes, it uses -D warnings, but --all-features enables local, which excludes test files that start with #![cfg(not(feature = "local"))]. I added a new Clippy check to prevent warnings like this from slipping through:

- name: Run clippy (all features except local)
run: |
FEATURES=$(cargo metadata --no-deps --format-version 1 \
| jq -r '[.packages[] | select(.name == "rmcp") | .features | keys[]
| select(startswith("__") | not)
| select(. != "local")] | join(",")')
cargo clippy --package rmcp --all-targets --no-default-features --features "$FEATURES" -- -D warnings

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

Labels

T-CI Changes to CI/CD workflows and configuration T-config Configuration file changes T-core Core library changes T-examples Example code changes T-test Testing related changes T-transport Transport layer changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants