Skip to content
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

Nightly clippy fails on array-size-threshold #10422

Closed
poliorcetics opened this issue Feb 28, 2023 · 2 comments · Fixed by #10423
Closed

Nightly clippy fails on array-size-threshold #10422

poliorcetics opened this issue Feb 28, 2023 · 2 comments · Fixed by #10423
Assignees
Labels
C-bug Category: Clippy is not doing the correct thing

Comments

@poliorcetics
Copy link

Summary

Using the following clippy.toml with nightly clippy

array-size-threshold = 10000

I get the following error:

error: error reading Clippy's configuration file `/private/tmp/toto/clippy.toml`: u128 is not supported for key `array-size-threshold`

Reproducer

I tried this:

cd /tmp
cargo new toto
cd toto
echo "array-size-threshold = 10000" > clippy.toml
cargo +nightly clippy

I expected this to happen: No warnings, successful compilation

Instead this happened:

cargo +nightly clippy
    Checking toto v0.1.0 (/private/tmp/toto)
error: error reading Clippy's configuration file `/private/tmp/toto/clippy.toml`: u128 is not supported for key `array-size-threshold`

error: could not compile `toto` due to previous error

Version

- cargo 1.69.0-nightly (9d5b32f50 2023-02-22)
- clippy 0.1.69 (7281249a 2023-02-27)

rustc 1.69.0-nightly (7281249a1 2023-02-27)
binary: rustc
commit-hash: 7281249a19a9755e9d889ee251ec323629caadab
commit-date: 2023-02-27
host: aarch64-apple-darwin
release: 1.69.0-nightly
LLVM version: 15.0.7

Additional Labels

No response

@poliorcetics poliorcetics added the C-bug Category: Clippy is not doing the correct thing label Feb 28, 2023
@poliorcetics
Copy link
Author

Also reproducible in beta

@rustbot label +regression-from-stable-to-beta

@rustbot
Copy link
Collaborator

rustbot commented Feb 28, 2023

Error: Label regression-from-stable-to-beta can only be set by Rust team members

Please file an issue on GitHub at triagebot if there's a problem with this bot, or reach out on #t-infra on Zulip.

@Alexendoo Alexendoo self-assigned this Feb 28, 2023
bors added a commit that referenced this issue Feb 28, 2023
Fix array-size-threshold config deserialization error

changelog: Fix error when providing an `array-size-threshold` in `clippy.toml`

Not entirely sure why it doesn't want to deserialize a u128, but converting it after the fact is an easy enough fix

Fixes #10422
@bors bors closed this as completed in acf70ea Feb 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: Clippy is not doing the correct thing
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants