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

rustFlake doesn't fail on cargo clippy AND cargo build warnings #165

Closed
bladyjoker opened this issue Dec 17, 2023 · 1 comment
Closed

rustFlake doesn't fail on cargo clippy AND cargo build warnings #165

bladyjoker opened this issue Dec 17, 2023 · 1 comment
Assignees
Labels
bug Something isn't working devops All things devops (Nix, language servers, editors, code quality etc) rust

Comments

@bladyjoker
Copy link
Contributor

warning: very complex type used. Consider factoring parts into `type` definitions
  --> src/indexer/callback.rs:22:5
   |
22 |     Arc<dyn Fn(Event) -> Pin<Box<dyn Future<Output = Result<(), E>> + Send + Sync>> + Send + Sync>,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity
   = note: `#[warn(clippy::type_complexity)]` on by default
warning: using `Result.or_else(|x| Err(y))`, which is more succinctly expressed as `map_err(|x| y)`
  --> src/indexer/callback.rs:43:9
   |
43 | /         rt.block_on(handle_event(input, |ev: Event| f(ev), &retry_policy, utils))
44 | |           .or_else(|err| {
45 | |             event!(Level::ERROR, label=%Events::EventHandlerFailure, ?err);
46 | |             Err(err)
47 | |           })
   | |____________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bind_instead_of_map
   = note: `#[warn(clippy::bind_instead_of_map)]` on by default
help: try
   |
44 ~           .map_err(|err| {
45 |             event!(Level::ERROR, label=%Events::EventHandlerFailure, ?err);
46 ~             err
   |
@bladyjoker bladyjoker added devops All things devops (Nix, language servers, editors, code quality etc) rust bug Something isn't working labels Dec 17, 2023
@bladyjoker bladyjoker changed the title rustFlake doesn't fail on Clippy warnings rustFlake doesn't fail on cargo clippy AND cargo build warnings Dec 17, 2023
@bladyjoker
Copy link
Contributor Author

Handled in mlabs-haskell/flake-lang.nix#33

@github-project-automation github-project-automation bot moved this from Todo to Done in Lambda Buffers Feb 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working devops All things devops (Nix, language servers, editors, code quality etc) rust
Projects
Status: Done
Development

No branches or pull requests

2 participants