8000 fix: clear clippy 1.99 double_must_use by avelino · Pull Request #115 · avelino/mcp · GitHub
[go: up one dir, main page]

Skip to content

fix: clear clippy 1.99 double_must_use - #115

Merged
avelino merged 1 commit into
mainfrom
avelino/fix/clippy-1-99-double-must-use
Oct 8, 2026
Merged

avelino merged 1 commit into
mainfrom
avelino/fix/clippy-1-99-double-must-use

Conversation

@avelino
@avelino avelino commented Oct 8, 2026 •
Copy link
Copy Markdown
Owner

Summary

Clippy 1.99 double_must_use fails CI on main (since a9ebe8f). async-trait 0.1.91 adds #[must_use] with no message on async trait methods whose return type is already must_use. 0.1.92 removes that attribute. The future stays must_use because the type is.

Actions in all five workflows are pinned to full SHAs, with the version in a comment. dtolnay/rust-toolchain is the v1 commit on master and now passes toolchain: stable, so it still installs stable. The publish job still sets CARGO_REGISTRY_TOKEN and runs the same cargo publish command.

.github/dependabot.yml updates github-actions and cargo weekly, each in one group.

How it was tested

Docs:

  • Clippy double_must_use: lint index. The lint checks for #[must_use] with no further information on a function that already returns a must_use type. The attribute is not needed. Alternatively, add text to the attribute. Context7 resolve-library-id for rust-clippy returned "Monthly quota exceeded" on every call, so this is the official page.
  • dtolnay/rust-toolchain README: a full SHA must be in master history, and toolchain must be passed when the ref is not @stable.
  • GitHub Actions secure use: pin third-party actions to a full-length commit SHA.
  • Dependabot options: package-ecosystem values github-actions and cargo, schedule.interval weekly, and groups with patterns.

Local, Rust 1.99.0 (b940084d7 2026-09-28):

$ cargo clippy --all-targets -- -D warnings
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.18s
$ cargo test
test result: ok. 877 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 3.15s

CI on this branch is green: https://github.com/avelino/mcp/actions/runs/37766685021 (test and docker both succeeded, including cargo clippy -- -D warnings and cargo test).

Could not test:

  • Context7 doc lookup. The server returned monthly quota exceeded.
  • Release, Release Beta, Publish Crate, and Publish Homebrew. Those need tags, release events, or CARGO_REGISTRY_TOKEN. Steps other than the action pins were left as they were.

async-trait 0.1.91 stamps #[must_use] with no message onto every async
trait method. Clippy 1.99 treats that as double_must_use because the
pinned boxed future is already must_use, and CI on stable has been red
since a9ebe8f. 0.1.92 stops emitting the attribute. The future stays
must_use through its type, which is the fix the lint asks for.

Workflow actions are pinned to full commit SHAs. rust-toolchain is the
v1 commit on master, with toolchain: stable passed explicitly, because
a SHA pin does not select the stable channel the way @stable did.
Publish still uses CARGO_REGISTRY_TOKEN the same way.

Dependabot checks github-actions and cargo weekly, each in one group.

Signed-off-by: Avelino <31996+avelino@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings October 8, 2026 10:55
Copilot AI 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.

🟢 Approval recommended

No blocking issues were identified in the dependency update, verified action pins, or Dependabot configuration; CI remains pending.

0 open findings

What changed in this PR

Updates async-trait to address Clippy’s double_must_use failure in the Rust CLI, and hardens dependency maintenance.

Changes:

  • Updates async-trait to 0.1.92.
  • Pins actions across five workflows to full commit SHAs while preserving stable Rust.
  • Adds weekly grouped Dependabot updates for Cargo and GitHub Actions.
File Description
Cargo.toml Raises the minimum async-trait version.
Cargo.lock Locks the updated version and checksum.
.github/​workflows/​release.yml Pins release actions and explicitly selects stable Rust.
.github/​workflows/​release-beta.yml Pins beta-release actions and selects stable Rust.
.github/​workflows/​publish-homebrew.yml Pins the checkout action.
.github/​workflows/​publish-crate.yml Pins publishing actions and selects stable Rust.
.github/​workflows/​ci.yml Pins CI actions and selects stable Rust.
.github/​dependabot.yml Configures weekly grouped dependency updates.

🧠 Review effort: Balanced


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

8000

@avelino
avelino merged commit b80eb8e into main Oct 8, 2026
8 checks passed
@avelino
avelino deleted the avelino/fix/clippy-1-99-double-must-use branch October 8, 2026 11:05
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.

2 participants

0