Ban wildcard imports via clippy::wildcard_imports - #4098
Open
ayushsingh82 wants to merge 1 commit into
Open
Conversation
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.
Summary
clippy::wildcard_importsat the workspace level ([workspace.lints.clippy]inCargo.toml)clippy::wildcard_importsalready exemptsuse super::*inside modules literally namedtests, which matches the exception described in the issueCloses #2629
Verification
cargo clippy --workspace --all-features --all-targets -- -D warnings: 0 wildcard-import violations (the only remaining failure locally is an unrelatedtikv-jemalloc-sysnative build error caused by a space in the local clone path — not present in CI)cargo teston the three touched crates (near-mpc-bounded-collections,mpc-contract,mpc-devnet): 484 tests passing, 0 failed (2 pre-existingmpc-contractABI test failures are unrelated — reproduced identically onmain, caused by a localcargo-nearCLI version mismatch)cargo fmt -- --check: cleanTest plan
wildcard_imports = "deny"lint