Repository navigation
fix(ci): build clean under Rust 1.99's clippy - #1517
Merged
Merged
Conversation
Two diagnostics new in 1.99 turned every `-D warnings` job red once CI's floating stable toolchain picked it up: - `clippy::assert_is_empty` (pedantic): 27 test assertions across 17 files now use `assert_eq!` / `assert_ne!` against a typed empty array, so a failure prints the offending contents instead of a bare boolean. - `semicolon_in_expressions_from_non_local_macros` fired on every closure-position `insta::assert_json_snapshot!`, because insta 1.48's macro ended in a stray `;`. insta 1.49.0 drops it, so both dev-dependency floors move from 1.29.0 to 1.49.0 and a fresh resolve cannot pick the old macro back up. Test code, a dev-dependency and the changelog only; nothing in the published library changes.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1517 +/- ##
===========================================
- Coverage 100.00% 98.02% -1.98%
===========================================
Files 5 359 +354
Lines 441 96210 +95769
Branches 10 95779 +95769
===========================================
+ Hits 441 94312 +93871
- Misses 0 1214 +1214
- Partials 0 684 +684
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
CI installs floating
stable, which became Rust 1.99.0 on 2026-09-28.Two diagnostics new in that release turn every
-D warningsjob red —clippy, the three
testlegs, coverage, chain audit, the wholefeaturesmatrix andlint— onmainand on every PR against it.The 21 failing checks on the seven most recent Dependabot PRs were this,
not the dependency bumps.
What
clippy::assert_is_empty(pedantic, so atwarnvia[workspace.lints]): 27 test assertions across 17 files move fromassert!(x.is_empty())toassert_eq!/assert_ne!against a typedempty array, so a failure prints the offending contents. Where a
serde_json::Valuewas being unwrapped to an array first, the paircollapses to one
assert_eq!(v[..], json!([])), which also prints thevalue when it is not an array at all.
semicolon_in_expressions_from_non_local_macros(future-incompat,-D warningspromotes it): fires on every closure-positioninsta::assert_json_snapshot!because insta 1.48's macro ends in astray
;. insta 1.49.0 drops it.Cargo.locktakes 1.49.0 and bothdev-dependency floors move
1.29.0→1.49.0, so a fresh resolvecannot pick the old macro back up.
CHANGELOG.mdentry under Unreleased / Fixed.Test code, a dev-dependency and the changelog only; nothing in the
published library changes.
Verification
make pre-commit→BCA_GATE: pass (gate=pre-commit)on Rust 1.99.0.cargo clippy --workspace --all-targets -- -D warningsclean with andwithout
--all-features; the workspace-excludedenums,fuzzandxtaskcrates were already clean.cargo metadata --lockedresolves on stable 1.99 and nightly.