-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Unable to allow same_item_push on beta and released Rust version #6002
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
Comments
We, like to run clippy on beta on our CI for various reasons. The principle one is so that when we move up to the new stable version of Rust we will have already fixed all the lints. But, as the above illustrates if the lint is a false positive, we will not be able to fix it, and if it is new we will not be able to allow it on stable. We have chosen to use clippy::all, which allows this lint that can't be named on stable. But, it's on a pretty largish expression, so that may allow other lints to creep in as well. Ideally, the lint name would be introduced in one version, and then the lint would be implemented in the next version. This way, on stable, we could just allow the lint by name. However, we may choose to drop the beta lint task from our CI, as this, while it has some benefits, and has caught at least one lint regression, it also has drawbacks. |
One option would be to allow the lint from the command line only for the beta pipeline: cargo clippy -- -A clippy::same_item_push See here for the relevant documentation. |
That is true (and would not require radical surgery on our CI). Thanks for the suggestion! |
Or allow |
Thanks! |
@bgurney-rh @mulkieran does the last suggestion solve your problem? Just asking in case we can close this issue :) |
Please feel free to close. thx. |
As part of preparing devicemapper-rs in Stratis for the 1.46 release, I was addressing a lint error message from clippy that appears to be a false one, since it's on a non-constant value (which would correspond to issue #5902).
(Related pull request from devicemapper-rs: stratis-storage/devicemapper-rs#576)
As part of continuous integration testing, clippy is executed on both the beta, and the released version. However, in the case of 1.46.0, and same_item_push, the lint cannot be found in the released version:
For now, we changed the allow to
#[allow(clippy::all)]
, but it would be preferable to be able to allow the specific lint on both the beta and released version.The text was updated successfully, but these errors were encountered: