Skip to content

Sweep: fix: git pull on downloaded plugin does not working (✓ Sandbox Passed) #382

Sweep: fix: git pull on downloaded plugin does not working (✓ Sandbox Passed)

Sweep: fix: git pull on downloaded plugin does not working (✓ Sandbox Passed) #382

Triggered via pull request January 2, 2024 05:55
Status Failure
Total duration 1m 9s
Artifacts

rust-clippy.yml

on: pull_request
Run rust-clippy analyzing
1m 0s
Run rust-clippy analyzing
Fit to window
Zoom out
Zoom in

Annotations

6 errors and 8 warnings
mismatched types: fluere-plugin/src/util.rs#L32
error[E0308]: mismatched types --> fluere-plugin/src/util.rs:32:5 | 7 | pub fn home_cache_path() -> Result<PathBuf, std::io::Error> { | ------------------------------- expected `std::result::Result<std::path::PathBuf, std::io::Error>` because of return type ... 32 | path_config | ^^^^^^^^^^^ expected `Result<PathBuf, Error>`, found `PathBuf` | = note: expected enum `std::result::Result<std::path::PathBuf, std::io::Error>` found struct `std::path::PathBuf` help: try wrapping the expression in `Ok` | 32 | Ok(path_config) | +++ +
the trait bound `std::result::Result<std::path::PathBuf, std::io::Error>: std::convert::AsRef<std::ffi::OsStr>` is not satisfied: fluere-plugin/src/downloader.rs#L13
error[E0277]: the trait bound `std::result::Result<std::path::PathBuf, std::io::Error>: std::convert::AsRef<std::ffi::OsStr>` is not satisfied --> fluere-plugin/src/downloader.rs:13:37 | 13 | let repository_path = Path::new(&path); | --------- ^^^^^ the trait `std::convert::AsRef<std::ffi::OsStr>` is not implemented for `std::result::Result<std::path::PathBuf, std::io::Error>` | | | required by a bound introduced by this call | note: required by a bound in `std::path::Path::new` --> /rustc/82e1608dfa6e0b5569232559e3d385fea5a93112/library/std/src/path.rs:2040:5
the method `clone` exists for enum `Result<PathBuf, Error>`, but its trait bounds were not satisfied: fluere-plugin/src/downloader.rs#L11
error[E0599]: the method `clone` exists for enum `Result<PathBuf, Error>`, but its trait bounds were not satisfied --> fluere-plugin/src/downloader.rs:11:38 | 11 | std::fs::create_dir_all(path.clone())?; | ^^^^^ method cannot be called on `Result<PathBuf, Error>` due to unsatisfied trait bounds --> /rustc/82e1608dfa6e0b5569232559e3d385fea5a93112/library/core/src/result.rs:502:1 | = note: doesn't satisfy `_: Clone` --> /rustc/82e1608dfa6e0b5569232559e3d385fea5a93112/library/std/src/io/error.rs:67:1 | = note: doesn't satisfy `std::io::Error: std::clone::Clone` | = note: the following trait bounds were not satisfied: `std::io::Error: std::clone::Clone` which is required by `std::result::Result<std::path::PathBuf, std::io::Error>: std::clone::Clone` note: the method `clone` exists on the type `std::path::PathBuf` --> /rustc/82e1608dfa6e0b5569232559e3d385fea5a93112/library/core/src/clone.rs:160:5 help: use the `?` operator to extract the `std::path::PathBuf` value, propagating a `Result::Err` value to the caller | 11 | std::fs::create_dir_all(path?.clone())?; | +
no method named `exists` found for enum `std::result::Result` in the current scope: fluere-plugin/src/downloader.rs#L10
error[E0599]: no method named `exists` found for enum `std::result::Result` in the current scope --> fluere-plugin/src/downloader.rs:10:14 | 10 | if !path.exists() { | ^^^^^^ method not found in `Result<PathBuf, Error>` | note: the method `exists` exists on the type `std::path::PathBuf` --> /rustc/82e1608dfa6e0b5569232559e3d385fea5a93112/library/std/src/path.rs:2861:5 help: use the `?` operator to extract the `std::path::PathBuf` value, propagating a `Result::Err` value to the caller | 10 | if !path?.exists() { | +
no method named `display` found for enum `std::result::Result` in the current scope: fluere-plugin/src/downloader.rs#L9
error[E0599]: no method named `display` found for enum `std::result::Result` in the current scope --> fluere-plugin/src/downloader.rs:9:40 | 9 | let cd_cmd = format!("cd {}", path.display()); | ^^^^^^^ method not found in `Result<PathBuf, Error>` | note: the method `display` exists on the type `std::path::PathBuf` --> /rustc/82e1608dfa6e0b5569232559e3d385fea5a93112/library/std/src/path.rs:2727:5 help: use the `?` operator to extract the `std::path::PathBuf` value, propagating a `Result::Err` value to the caller | 9 | let cd_cmd = format!("cd {}", path?.display()); | +
Run rust-clippy analyzing
Clippy had exited with the 101 exit code
this import is redundant: fluere-plugin/src/downloader.rs#L2
warning: this import is redundant --> fluere-plugin/src/downloader.rs:2:1 | 2 | use git2; | ^^^^^^^^^ help: remove it entirely | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports = note: `#[warn(clippy::single_component_path_imports)]` on by default
this function has too many arguments (27/7): fluereflow/src/types/fluereflow.rs#L63
warning: this function has too many arguments (27/7) --> fluereflow/src/types/fluereflow.rs:63:5 | 63 | / pub fn new( 64 | | source: IpAddr, 65 | | destination: IpAddr, 66 | | d_pkts: u32, ... | 90 | | tos: u8, 91 | | ) -> FluereRecord { | |_____________________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments = note: `#[warn(clippy::too_many_arguments)]` on by default
returning the result of a `let` binding from a block: fluere-config/src/init.rs#L75
warning: returning the result of a `let` binding from a block --> fluere-config/src/init.rs:75:5 | 74 | let path_config = path_base.join("fluere"); | ------------------------------------------- unnecessary `let` binding 75 | path_config | ^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return = note: `#[warn(clippy::let_and_return)]` on by default help: return the expression directly | 74 ~ 75 ~ path_base.join("fluere") |
Run rust-clippy analyzing
The following actions uses node12 which is deprecated and will be forced to run on node16: actions-rs/toolchain@v1, actions-rs/clippy-check@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
Run rust-clippy analyzing
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Run rust-clippy analyzing
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Run rust-clippy analyzing
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Run rust-clippy analyzing
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/