[INFO] cloning repository https://github.com/suislanchez/tinyclaw
[INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/suislanchez/tinyclaw" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsuislanchez%2Ftinyclaw", kill_on_drop: false }`
[INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsuislanchez%2Ftinyclaw'...
[INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }`
[INFO] [stdout] 61043a01a203a05d85b4e550907190005ef77a84
[INFO] linting suislanchez/tinyclaw/61043a01a203a05d85b4e550907190005ef77a84 against nightly for clippy-nonminimal_bool-denied
[INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsuislanchez%2Ftinyclaw" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }`
[INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'...
[INFO] [stderr] done.
[INFO] removed /workspace/builds/worker-4-tc1/source/rust-toolchain.toml
[INFO] started tweaking git repo https://github.com/suislanchez/tinyclaw
[INFO] finished tweaking git repo https://github.com/suislanchez/tinyclaw
[INFO] tweaked toml for git repo https://github.com/suislanchez/tinyclaw written to /workspace/builds/worker-4-tc1/source/Cargo.toml
[INFO] validating manifest of git repo https://github.com/suislanchez/tinyclaw on toolchain nightly
[INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }`
[INFO] crate git repo https://github.com/suislanchez/tinyclaw already has a lockfile, it will not be regenerated
[INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }`
[INFO] [stderr] Downloading crates ...
[INFO] [stderr] Downloaded quoted_printable v0.5.1
[INFO] [stderr] Downloaded tonic-prost v0.14.4
[INFO] [stderr] Downloaded email-encoding v0.4.1
[INFO] [stderr] Downloaded chumsky v0.9.3
[INFO] [stderr] Downloaded tonic v0.14.4
[INFO] [stderr] Downloaded lettre v0.11.19
[INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }`
[INFO] [stdout] f221c5038e844e682e033ba0198c05a378fa4a09e21a8d39edff3cba34a4c11c
[INFO] running `Command { std: "docker" "start" "-a" "f221c5038e844e682e033ba0198c05a378fa4a09e21a8d39edff3cba34a4c11c", kill_on_drop: false }`
[INFO] running `Command { std: "docker" "inspect" "f221c5038e844e682e033ba0198c05a378fa4a09e21a8d39edff3cba34a4c11c", kill_on_drop: false }`
[INFO] running `Command { std: "docker" "rm" "-f" "f221c5038e844e682e033ba0198c05a378fa4a09e21a8d39edff3cba34a4c11c", kill_on_drop: false }`
[INFO] [stdout] f221c5038e844e682e033ba0198c05a378fa4a09e21a8d39edff3cba34a4c11c
[INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "clippy" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }`
[INFO] [stdout] 10b0c836063c701c47d80c9cdc1634bcde16ee1f7e9c7c147b050c6bceace6ab
[INFO] running `Command { std: "docker" "start" "-a" "10b0c836063c701c47d80c9cdc1634bcde16ee1f7e9c7c147b050c6bceace6ab", kill_on_drop: false }`
[INFO] [stderr] Compiling unicode-ident v1.0.23
[INFO] [stderr] Compiling aws-lc-rs v1.15.4
[INFO] [stderr] Compiling ring v0.17.14
[INFO] [stderr] Compiling rustls v0.23.36
[INFO] [stderr] Compiling aws-lc-sys v0.37.1
[INFO] [stderr] Checking crypto-common v0.1.7
[INFO] [stderr] Compiling anyhow v1.0.101
[INFO] [stderr] Compiling object v0.37.3
[INFO] [stderr] Checking ahash v0.8.12
[INFO] [stderr] Checking serde_json v1.0.149
[INFO] [stderr] Compiling mime_guess v2.0.5
[INFO] [stderr] Checking rand_chacha v0.9.0
[INFO] [stderr] Compiling rustix v0.38.44
[INFO] [stderr] Compiling libsqlite3-sys v0.30.1
[INFO] [stderr] Checking rand_chacha v0.3.1
[INFO] [stderr] Checking indexmap v2.13.0
[INFO] [stderr] Compiling prometheus v0.13.4
[INFO] [stderr] Compiling proc-macro2 v1.0.106
[INFO] [stderr] Checking digest v0.10.7
[INFO] [stderr] Checking hashbrown v0.14.5
[INFO] [stderr] Checking cipher v0.4.4
[INFO] [stderr] Checking universal-hash v0.5.1
[INFO] [stderr] Checking regex-automata v0.4.14
[INFO] [stderr] Checking nom v7.1.3
[INFO] [stderr] Checking rand v0.9.2
[INFO] [stderr] Checking poly1305 v0.8.0
[INFO] [stderr] Checking rand v0.8.5
[INFO] [stderr] Checking sha1 v0.10.6
[INFO] [stderr] Checking clap_builder v4.5.58
[INFO] [stderr] Checking chacha20 v0.9.1
[INFO] [stderr] Checking aead v0.5.2
[INFO] [stderr] Checking console v0.15.11
[INFO] [stderr] Checking hashlink v0.9.1
[INFO] [stderr] Checking fuzzy-matcher v0.3.7
[INFO] [stderr] Checking serde_path_to_error v0.1.20
[INFO] [stderr] Checking email-encoding v0.4.1
[INFO] [stderr] Compiling quote v1.0.44
[INFO] [stderr] Checking nom v8.0.0
[INFO] [stderr] Checking quoted_printable v0.5.1
[INFO] [stderr] Checking fallible-iterator v0.3.0
[INFO] [stderr] Checking crossterm v0.28.1
[INFO] [stderr] Checking email_address v0.2.9
[INFO] [stderr] Checking shell-words v1.1.1
[INFO] [stderr] Compiling syn v2.0.116
[INFO] [stderr] Checking tracing-subscriber v0.3.22
[INFO] [stderr] Checking chacha20poly1305 v0.10.1
[INFO] [stderr] Checking shellexpand v3.1.1
[INFO] [stderr] Checking hmac v0.12.1
[INFO] [stderr] Checking sha2 v0.10.9
[INFO] [stderr] Checking uuid v1.21.0
[INFO] [stderr] Checking hostname v0.4.2
[INFO] [stderr] Checking regex v1.12.3
[INFO] [stderr] Compiling ar_archive_writer v0.5.1
[INFO] [stderr] Compiling psm v0.1.30
[INFO] [stderr] Checking stacker v0.1.23
[INFO] [stderr] Checking chumsky v0.9.3
[INFO] [stderr] Compiling synstructure v0.13.2
[INFO] [stderr] Compiling darling_core v0.23.0
[INFO] [stderr] Compiling tokio-macros v2.6.0
[INFO] [stderr] Compiling zerovec-derive v0.11.2
[INFO] [stderr] Compiling futures-macro v0.3.32
[INFO] [stderr] Compiling displaydoc v0.2.5
[INFO] [stderr] Compiling serde_derive v1.0.228
[INFO] [stderr] Compiling tracing-attributes v0.1.31
[INFO] [stderr] Compiling async-trait v0.1.89
[INFO] [stderr] Compiling thiserror-impl v2.0.18
[INFO] [stderr] Compiling thiserror-impl v1.0.69
[INFO] [stderr] Compiling pin-project-internal v1.1.10
[INFO] [stderr] Compiling zerofrom-derive v0.1.6
[INFO] [stderr] Compiling yoke-derive v0.8.1
[INFO] [stderr] Checking tokio v1.49.0
[INFO] [stderr] Compiling prost-derive v0.14.3
[INFO] [stderr] Checking futures-util v0.3.32
[INFO] [stderr] Checking pin-project v1.1.10
[INFO] [stderr] Compiling strum_macros v0.26.4
[INFO] [stderr] Compiling hashify v0.2.7
[INFO] [stderr] Compiling clap_derive v4.5.55
[INFO] [stderr] Checking thiserror v2.0.18
[INFO] [stderr] Checking tracing v0.1.44
[INFO] [stderr] Checking zerofrom v0.1.6
[INFO] [stderr] Checking opentelemetry v0.31.0
[INFO] [stderr] Checking thiserror v1.0.69
[INFO] [stderr] Checking dialoguer v0.11.0
[INFO] [stderr] Checking yoke v0.8.1
[INFO] [stderr] Checking mail-parser v0.11.2
[INFO] [stderr] Checking zerovec v0.11.5
[INFO] [stderr] Checking zerotrie v0.2.3
[INFO] [stderr] Compiling darling_macro v0.23.0
[INFO] [stderr] Checking serde v1.0.228
[INFO] [stderr] Compiling darling v0.23.0
[INFO] [stderr] Checking strum v0.26.3
[INFO] [stderr] Checking prost v0.14.3
[INFO] [stderr] Compiling instability v0.3.11
[INFO] [stderr] Checking tinystr v0.8.2
[INFO] [stderr] Checking potential_utf v0.1.4
[INFO] [stderr] Checking icu_locale_core v2.1.1
[INFO] [stderr] Checking icu_collections v2.1.1
[INFO] [stderr] Checking serde_urlencoded v0.7.1
[INFO] [stderr] Checking toml_datetime v0.6.11
[INFO] [stderr] Checking serde_spanned v0.6.9
[INFO] [stderr] Checking chrono v0.4.43
[INFO] [stderr] Checking ratatui v0.29.0
[INFO] [stderr] Checking icu_provider v2.1.1
[INFO] [stderr] Checking clap v4.5.58
[INFO] [stderr] Checking icu_normalizer v2.1.1
[INFO] [stderr] Checking icu_properties v2.1.2
[INFO] [stderr] Checking toml_edit v0.22.27
[INFO] [stderr] Checking futures-executor v0.3.32
[INFO] [stderr] Checking axum-core v0.4.5
[INFO] [stderr] Checking opentelemetry_sdk v0.31.0
[INFO] [stderr] Checking rusqlite v0.32.1
[INFO] [stderr] Checking rustls-webpki v0.103.9
[INFO] [stderr] Checking toml v0.8.23
[INFO] [stderr] Checking cron v0.12.1
[INFO] [stderr] Checking idna_adapter v1.2.1
[INFO] [stderr] Checking idna v1.1.0
[INFO] [stderr] Checking url v2.5.8
[INFO] [stderr] Checking hyper v1.8.1
[INFO] [stderr] Checking tokio-stream v0.1.18
[INFO] [stderr] Checking tower v0.5.3
[INFO] [stderr] Checking tokio-util v0.7.18
[INFO] [stderr] Checking tonic v0.14.4
[INFO] [stderr] Checking tokio-test v0.4.5
[INFO] [stderr] Checking tower-http v0.6.8
[INFO] [stderr] Checking tonic-prost v0.14.4
[INFO] [stderr] Checking hyper-util v0.1.20
[INFO] [stderr] Checking opentelemetry-proto v0.31.0
[INFO] [stderr] Checking axum v0.7.9
[INFO] [stderr] Checking tokio-rustls v0.26.4
[INFO] [stderr] Checking tungstenite v0.24.0
[INFO] [stderr] Checking lettre v0.11.19
[INFO] [stderr] Checking hyper-rustls v0.27.7
[INFO] [stderr] Checking reqwest v0.12.28
[INFO] [stderr] Checking tokio-tungstenite v0.24.0
[INFO] [stderr] Checking opentelemetry-http v0.31.0
[INFO] [stderr] Checking opentelemetry-otlp v0.31.0
[INFO] [stderr] Checking tinyclaw v0.1.0 (/opt/rustwide/workdir)
[INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize`
[INFO] [stdout] --> src/channels/email_channel.rs:16:13
[INFO] [stdout] |
[INFO] [stdout] 16 | use serde::{Deserialize, Serialize};
[INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/skillforge/integrate.rs:99:13
[INFO] [stdout] |
[INFO] [stdout] 99 | / r#"# {name}
[INFO] [stdout] 100 | |
[INFO] [stdout] 101 | | > Auto-generated by SkillForge
[INFO] [stdout] ... |
[INFO] [stdout] 126 | | Review before enabling in production.
[INFO] [stdout] 127 | | "#,
[INFO] [stdout] | |__^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/lib.rs:1:22
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::needless_raw_string_hashes)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 99 ~ r"# {name}
[INFO] [stdout] 100 |
[INFO] [stdout] ...
[INFO] [stdout] 126 | Review before enabling in production.
[INFO] [stdout] 127 ~ ",
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/agent/loop_.rs:596:24
[INFO] [stdout] |
[INFO] [stdout] 596 | let response = r#"
[INFO] [stdout] | ________________________^
[INFO] [stdout] 597 | | not valid json
[INFO] [stdout] 598 | |
[INFO] [stdout] 599 | | Some text after."#;
[INFO] [stdout] | |__________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/lib.rs:1:22
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::needless_raw_string_hashes)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 596 ~ let response = r"
[INFO] [stdout] 597 | not valid json
[INFO] [stdout] 598 |
[INFO] [stdout] 599 ~ Some text after.";
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize`
[INFO] [stdout] --> src/channels/email_channel.rs:16:13
[INFO] [stdout] |
[INFO] [stdout] 16 | use serde::{Deserialize, Serialize};
[INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/identity.rs:769:20
[INFO] [stdout] |
[INFO] [stdout] 769 | let json = r#"{}"#;
[INFO] [stdout] | ^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 769 - let json = r#"{}"#;
[INFO] [stdout] 769 + let json = r"{}";
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: binding's name is too similar to existing binding
[INFO] [stdout] --> src/providers/router.rs:242:13
[INFO] [stdout] |
[INFO] [stdout] 242 | let router = RouterProvider::new(provider_list, route_list, "default-model".to_string());
[INFO] [stdout] | ^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: existing binding defined here
[INFO] [stdout] --> src/providers/router.rs:211:9
[INFO] [stdout] |
[INFO] [stdout] 211 | routes: Vec<(&str, &str, &str)>,
[INFO] [stdout] | ^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#similar_names
[INFO] [stdout] = note: `#[warn(clippy::similar_names)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/skillforge/integrate.rs:99:13
[INFO] [stdout] |
[INFO] [stdout] 99 | / r#"# {name}
[INFO] [stdout] 100 | |
[INFO] [stdout] 101 | | > Auto-generated by SkillForge
[INFO] [stdout] ... |
[INFO] [stdout] 126 | | Review before enabling in production.
[INFO] [stdout] 127 | | "#,
[INFO] [stdout] | |__^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 99 ~ r"# {name}
[INFO] [stdout] 100 |
[INFO] [stdout] ...
[INFO] [stdout] 126 | Review before enabling in production.
[INFO] [stdout] 127 ~ ",
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/agent/loop_.rs:27:22
[INFO] [stdout] |
[INFO] [stdout] 27 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/lib.rs:1:9
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_map_or)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 27 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 27 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/agent/loop_.rs:38:17
[INFO] [stdout] |
[INFO] [stdout] 38 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout] = note: `#[warn(clippy::bool_to_int_with_if)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/agent/loop_.rs:63:49
[INFO] [stdout] |
[INFO] [stdout] 63 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout] = note: `#[warn(clippy::redundant_closure_for_method_calls)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/agent/loop_.rs:195:10
[INFO] [stdout] |
[INFO] [stdout] 195 | /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] = note: `#[warn(clippy::doc_markdown)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 195 - /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] 195 + /// Uses `tokio::spawn` with Arc-wrapped tools for true parallelism.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:210:51
[INFO] [stdout] |
[INFO] [stdout] 210 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 210 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 210 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:242:51
[INFO] [stdout] |
[INFO] [stdout] 242 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 242 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 242 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/discord.rs:352:9
[INFO] [stdout] |
[INFO] [stdout] 352 | / self.client
[INFO] [stdout] 353 | | .get("https://discord.com/api/v10/users/@me")
[INFO] [stdout] 354 | | .header("Authorization", format!("Bot {}", self.bot_token))
[INFO] [stdout] 355 | | .send()
[INFO] [stdout] 356 | | .await
[INFO] [stdout] 357 | | .map(|r| r.status().is_success())
[INFO] [stdout] 358 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] = note: `#[warn(clippy::map_unwrap_or)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 357 - .map(|r| r.status().is_success())
[INFO] [stdout] 358 - .unwrap_or(false)
[INFO] [stdout] 357 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/irc.rs:13:43
[INFO] [stdout] |
[INFO] [stdout] 13 | const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] = note: `#[warn(clippy::duration_suboptimal_units)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 13 - const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] 13 + const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_mins(5);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:432:21
[INFO] [stdout] |
[INFO] [stdout] 432 | / if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) {
[INFO] [stdout] 433 | | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] 434 | | // CAP * ACK :sasl — server accepted, start SASL auth
[INFO] [stdout] 435 | | let mut guard = self.writer.lock().await;
[INFO] [stdout] ... |
[INFO] [stdout] 450 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 431 ~ "CAP"
[INFO] [stdout] 432 ~ if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) => {
[INFO] [stdout] 433 | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] ...
[INFO] [stdout] 449 | }
[INFO] [stdout] 450 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:455:21
[INFO] [stdout] |
[INFO] [stdout] 455 | / if sasl_pending && msg.params.first().is_some_and(|p| p == "+") {
[INFO] [stdout] 456 | | let encoded = encode_sasl_plain(
[INFO] [stdout] 457 | | ¤t_nick,
[INFO] [stdout] 458 | | self.sasl_password.as_deref().unwrap_or(""),
[INFO] [stdout] ... |
[INFO] [stdout] 464 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 453 ~ "AUTHENTICATE"
[INFO] [stdout] 454 | // Server sends "AUTHENTICATE +" to request credentials
[INFO] [stdout] 455 ~ if sasl_pending && msg.params.first().is_some_and(|p| p == "+") => {
[INFO] [stdout] 456 | let encoded = encode_sasl_plain(
[INFO] [stdout] ...
[INFO] [stdout] 463 | }
[INFO] [stdout] 464 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/slack.rs:182:9
[INFO] [stdout] |
[INFO] [stdout] 182 | / self.client
[INFO] [stdout] 183 | | .get("https://slack.com/api/auth.test")
[INFO] [stdout] 184 | | .bearer_auth(&self.bot_token)
[INFO] [stdout] 185 | | .send()
[INFO] [stdout] 186 | | .await
[INFO] [stdout] 187 | | .map(|r| r.status().is_success())
[INFO] [stdout] 188 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 187 - .map(|r| r.status().is_success())
[INFO] [stdout] 188 - .unwrap_or(false)
[INFO] [stdout] 187 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/telegram.rs:412:13
[INFO] [stdout] |
[INFO] [stdout] 412 | / anyhow::bail!(
[INFO] [stdout] 413 | | "Telegram sendMessage failed (markdown {}: {}; plain {}: {})",
[INFO] [stdout] 414 | | markdown_status,
[INFO] [stdout] 415 | | markdown_err,
[INFO] [stdout] 416 | | plain_status,
[INFO] [stdout] 417 | | plain_err
[INFO] [stdout] 418 | | );
[INFO] [stdout] | |_____________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] = note: `#[warn(clippy::uninlined_format_args)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/telegram.rs:534:9
[INFO] [stdout] |
[INFO] [stdout] 534 | / self.client
[INFO] [stdout] 535 | | .get(self.api_url("getMe"))
[INFO] [stdout] 536 | | .send()
[INFO] [stdout] 537 | | .await
[INFO] [stdout] 538 | | .map(|r| r.status().is_success())
[INFO] [stdout] 539 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 538 - .map(|r| r.status().is_success())
[INFO] [stdout] 539 - .unwrap_or(false)
[INFO] [stdout] 538 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/whatsapp.rs:192:32
[INFO] [stdout] |
[INFO] [stdout] 192 | tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 192 - tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] 192 + tokio::time::sleep(std::time::Duration::from_hours(1)).await;
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/whatsapp.rs:200:9
[INFO] [stdout] |
[INFO] [stdout] 200 | / self.client
[INFO] [stdout] 201 | | .get(&url)
[INFO] [stdout] 202 | | .header("Authorization", format!("Bearer {}", self.access_token))
[INFO] [stdout] 203 | | .send()
[INFO] [stdout] 204 | | .await
[INFO] [stdout] 205 | | .map(|r| r.status().is_success())
[INFO] [stdout] 206 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 205 - .map(|r| r.status().is_success())
[INFO] [stdout] 206 - .unwrap_or(false)
[INFO] [stdout] 205 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/channels/mod.rs:97:10
[INFO] [stdout] |
[INFO] [stdout] 97 | /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 97 - /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] 97 + /// Load `OpenClaw` format bootstrap files into the prompt.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/channels/mod.rs:276:17
[INFO] [stdout] |
[INFO] [stdout] 276 | / trimmed
[INFO] [stdout] 277 | | .char_indices()
[INFO] [stdout] 278 | | .nth(BOOTSTRAP_MAX_CHARS)
[INFO] [stdout] 279 | | .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 | | .unwrap_or(trimmed)
[INFO] [stdout] | |_______________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 279 - .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 - .unwrap_or(trimmed)
[INFO] [stdout] 279 + .map_or(trimmed, |(idx, _)| &trimmed[..idx])
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (113/100)
[INFO] [stdout] --> src/channels/mod.rs:365:1
[INFO] [stdout] |
[INFO] [stdout] 365 | pub async fn doctor_channels(config: Config) -> Result<()> {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout] = note: `#[warn(clippy::too_many_lines)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/mod.rs:756:35
[INFO] [stdout] |
[INFO] [stdout] 756 | let timeout_msg = format!(
[INFO] [stdout] | ___________________________________^
[INFO] [stdout] 757 | | "LLM response timed out after {}s",
[INFO] [stdout] 758 | | CHANNEL_MESSAGE_TIMEOUT_SECS
[INFO] [stdout] 759 | | );
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/config/schema.rs:332:30
[INFO] [stdout] |
[INFO] [stdout] 332 | /// OTLP endpoint (e.g. "http://localhost:4318"). Only used when backend = "otel".
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:336:38
[INFO] [stdout] |
[INFO] [stdout] 336 | /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 336 - /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] 336 + /// Service name reported to the `OTel` collector. Defaults to "tinyclaw".
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:474:1
[INFO] [stdout] |
[INFO] [stdout] 474 | fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_wraps)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 474 - fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] 474 + fn default_docker_memory_limit_mb() -> u64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 475 - Some(512)
[INFO] [stdout] 475 + 512
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:478:1
[INFO] [stdout] |
[INFO] [stdout] 478 | fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 478 - fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] 478 + fn default_docker_cpu_limit() -> f64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 479 - Some(1.0)
[INFO] [stdout] 479 + 1.0
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:794:9
[INFO] [stdout] |
[INFO] [stdout] 794 | /// NickServ IDENTIFY password
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 794 - /// NickServ IDENTIFY password
[INFO] [stdout] 794 + /// `NickServ` IDENTIFY password
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:796:30
[INFO] [stdout] |
[INFO] [stdout] 796 | /// SASL PLAIN password (IRCv3)
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 796 - /// SASL PLAIN password (IRCv3)
[INFO] [stdout] 796 + /// SASL PLAIN password (`IRCv3`)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:904:13
[INFO] [stdout] |
[INFO] [stdout] 904 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout] = note: `#[warn(clippy::assigning_clones)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::Config { config_path: config_path.clone(), workspace_dir: tinyclaw_dir.join("workspace"), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/config/schema.rs:908:13
[INFO] [stdout] |
[INFO] [stdout] 908 | let mut config = Config::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout] = note: `#[warn(clippy::field_reassign_with_default)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:1:32
[INFO] [stdout] |
[INFO] [stdout] 1 | //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] 1 + //! Identity system supporting `OpenClaw` (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:5:13
[INFO] [stdout] |
[INFO] [stdout] 5 | //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 5 - //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] 5 + //! JSON to `TinyClaw`'s system prompt format.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/identity.rs:15:23
[INFO] [stdout] |
[INFO] [stdout] 15 | /// and behavior. See https://aieos.org for the full specification.
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:214:10
[INFO] [stdout] |
[INFO] [stdout] 214 | /// with TinyClaw's agent system.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 214 - /// with TinyClaw's agent system.
[INFO] [stdout] 214 + /// with `TinyClaw`'s agent system.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (198/100)
[INFO] [stdout] --> src/identity.rs:215:1
[INFO] [stdout] |
[INFO] [stdout] 215 | pub fn aieos_to_system_prompt(identity: &AieosIdentity) -> String {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:225:25
[INFO] [stdout] |
[INFO] [stdout] 225 | let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 225 - let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] 225 + let _ = writeln!(prompt, "**Name:** {first}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:227:29
[INFO] [stdout] |
[INFO] [stdout] 227 | let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 227 - let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] 227 + let _ = writeln!(prompt, "**Full Name:** {first} {last}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:230:25
[INFO] [stdout] |
[INFO] [stdout] 230 | let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 230 - let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] 230 + let _ = writeln!(prompt, "**Name:** {full}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:234:25
[INFO] [stdout] |
[INFO] [stdout] 234 | let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 234 - let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] 234 + let _ = writeln!(prompt, "**Nickname:** {nickname}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:239:21
[INFO] [stdout] |
[INFO] [stdout] 239 | let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 239 - let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] 239 + let _ = writeln!(prompt, "**Bio:** {bio}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:243:21
[INFO] [stdout] |
[INFO] [stdout] 243 | let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 243 - let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] 243 + let _ = writeln!(prompt, "**Origin:** {origin}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:247:21
[INFO] [stdout] |
[INFO] [stdout] 247 | let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 247 - let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] 247 + let _ = writeln!(prompt, "**Residence:** {residence}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:258:21
[INFO] [stdout] |
[INFO] [stdout] 258 | let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 258 - let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] 258 + let _ = writeln!(prompt, "**MBTI:** {mbti}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:264:25
[INFO] [stdout] |
[INFO] [stdout] 264 | let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 264 - let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] 264 + let _ = writeln!(prompt, "- Openness: {o:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:267:25
[INFO] [stdout] |
[INFO] [stdout] 267 | let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 267 - let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] 267 + let _ = writeln!(prompt, "- Conscientiousness: {c:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:270:25
[INFO] [stdout] |
[INFO] [stdout] 270 | let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 270 - let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] 270 + let _ = writeln!(prompt, "- Extraversion: {e:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:273:25
[INFO] [stdout] |
[INFO] [stdout] 273 | let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 273 - let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] 273 + let _ = writeln!(prompt, "- Agreeableness: {a:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:276:25
[INFO] [stdout] |
[INFO] [stdout] 276 | let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 276 - let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] 276 + let _ = writeln!(prompt, "- Neuroticism: {n:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:284:29
[INFO] [stdout] |
[INFO] [stdout] 284 | let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 284 - let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] 284 + let _ = writeln!(prompt, "- {trait_name}: {weight:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:293:29
[INFO] [stdout] |
[INFO] [stdout] 293 | let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 293 - let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] 293 + let _ = writeln!(prompt, "- {principle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:306:21
[INFO] [stdout] |
[INFO] [stdout] 306 | let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 306 - let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] 306 + let _ = writeln!(prompt, "**Style:** {style}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:310:21
[INFO] [stdout] |
[INFO] [stdout] 310 | let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 310 - let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] 310 + let _ = writeln!(prompt, "**Formality Level:** {formality}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:317:29
[INFO] [stdout] |
[INFO] [stdout] 317 | let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 317 - let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] 317 + let _ = writeln!(prompt, "- \"{phrase}\"");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:326:29
[INFO] [stdout] |
[INFO] [stdout] 326 | let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 326 - let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] 326 + let _ = writeln!(prompt, "- {word}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:339:21
[INFO] [stdout] |
[INFO] [stdout] 339 | let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 339 - let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] 339 + let _ = writeln!(prompt, "**Core Drive:** {drive}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:346:29
[INFO] [stdout] |
[INFO] [stdout] 346 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 346 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 346 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:355:29
[INFO] [stdout] |
[INFO] [stdout] 355 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 355 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 355 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:364:29
[INFO] [stdout] |
[INFO] [stdout] 364 | let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 364 - let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] 364 + let _ = writeln!(prompt, "- {fear}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:380:29
[INFO] [stdout] |
[INFO] [stdout] 380 | let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 380 - let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] 380 + let _ = writeln!(prompt, "- {skill}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:389:29
[INFO] [stdout] |
[INFO] [stdout] 389 | let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 389 - let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] 389 + let _ = writeln!(prompt, "- {tool}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:402:21
[INFO] [stdout] |
[INFO] [stdout] 402 | let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 402 - let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] 402 + let _ = writeln!(prompt, "**Origin Story:** {story}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:409:29
[INFO] [stdout] |
[INFO] [stdout] 409 | let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 409 - let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] 409 + let _ = writeln!(prompt, "- {edu}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:415:21
[INFO] [stdout] |
[INFO] [stdout] 415 | let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 415 - let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] 415 + let _ = writeln!(prompt, "\n**Occupation:** {occupation}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:426:21
[INFO] [stdout] |
[INFO] [stdout] 426 | let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 426 - let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] 426 + let _ = writeln!(prompt, "{appearance}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:430:21
[INFO] [stdout] |
[INFO] [stdout] 430 | let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 430 - let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] 430 + let _ = writeln!(prompt, "**Avatar Description:** {avatar}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:444:29
[INFO] [stdout] |
[INFO] [stdout] 444 | let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 444 - let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] 444 + let _ = writeln!(prompt, "- {hobby}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:453:29
[INFO] [stdout] |
[INFO] [stdout] 453 | let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 453 - let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] 453 + let _ = writeln!(prompt, "- {category}: {value}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:459:21
[INFO] [stdout] |
[INFO] [stdout] 459 | let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 459 - let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] 459 + let _ = writeln!(prompt, "\n**Lifestyle:** {lifestyle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:50
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either `aieos_path` or aieos_inline is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:64
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either aieos_path or `aieos_inline` is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/hygiene.rs:333:5
[INFO] [stdout] |
[INFO] [stdout] 333 | / fs::metadata(path)
[INFO] [stdout] 334 | | .and_then(|meta| meta.modified())
[INFO] [stdout] 335 | | .map(|modified| modified < cutoff)
[INFO] [stdout] 336 | | .unwrap_or(false)
[INFO] [stdout] | |_________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 335 - .map(|modified| modified < cutoff)
[INFO] [stdout] 336 - .unwrap_or(false)
[INFO] [stdout] 335 + .is_ok_and(|modified| modified < cutoff)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/memory/sqlite.rs:133:45
[INFO] [stdout] |
[INFO] [stdout] 133 | /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 133 - /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] 133 + /// Uses SHA-256 (truncated) instead of `DefaultHasher`, which is
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/sqlite.rs:586:9
[INFO] [stdout] |
[INFO] [stdout] 586 | / self.conn
[INFO] [stdout] 587 | | .lock()
[INFO] [stdout] 588 | | .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 588 - .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 - .unwrap_or(false)
[INFO] [stdout] 588 + .is_ok_and(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/observability/otel.rs:30:22
[INFO] [stdout] |
[INFO] [stdout] 30 | /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 30 - /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] 30 + /// Create a new `OTel` observer exporting to the given OTLP endpoint.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `i64` may wrap around the value
[INFO] [stdout] --> src/observability/otel.rs:186:69
[INFO] [stdout] |
[INFO] [stdout] 186 | span.set_attribute(KeyValue::new("tokens_used", *t as i64));
[INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, use `cast_signed()` instead: `(*t).cast_signed()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_wrap
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_wrap)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:266:38
[INFO] [stdout] |
[INFO] [stdout] 266 | self.tokens_used.add(*t as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*t)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:269:45
[INFO] [stdout] |
[INFO] [stdout] 269 | self.active_sessions.record(*s as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*s)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:272:41
[INFO] [stdout] |
[INFO] [stdout] 272 | self.queue_depth.record(*d as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*d)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/onboard/wizard.rs:1733:33
[INFO] [stdout] |
[INFO] [stdout] 1733 | let port: u16 = match port_str.trim().parse() {
[INFO] [stdout] | _________________________________^
[INFO] [stdout] 1734 | | Ok(p) => p,
[INFO] [stdout] 1735 | | Err(_) => {
[INFO] [stdout] 1736 | | println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] ... |
[INFO] [stdout] 1739 | | };
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] = note: `#[warn(clippy::single_match_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1733 ~ let port: u16 = if let Ok(p) = port_str.trim().parse() { p } else {
[INFO] [stdout] 1734 ~ println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] 1735 + 6697
[INFO] [stdout] 1736 ~ };
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/anthropic.rs:85:24
[INFO] [stdout] |
[INFO] [stdout] 85 | let base_url = base_url
[INFO] [stdout] | ________________________^
[INFO] [stdout] 86 | | .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 | | .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] | |___________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 86 - .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 - .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] 86 + .map_or("https://api.anthropic.com", |u| u.trim_end_matches('/'))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/anthropic.rs:96:26
[INFO] [stdout] |
[INFO] [stdout] 96 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 96 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 96 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/compatible.rs:41:26
[INFO] [stdout] |
[INFO] [stdout] 41 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 41 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 41 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/compatible.rs:49:5
[INFO] [stdout] |
[INFO] [stdout] 49 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 50 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 51 | | tracker.add(&TokenUsage {
[INFO] [stdout] 52 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 57 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] = note: `#[warn(clippy::ref_option)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 49 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 49 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:59:63
[INFO] [stdout] |
[INFO] [stdout] 59 | /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 59 - /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] 59 + /// Build the full URL for chat completions, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:60:73
[INFO] [stdout] |
[INFO] [stdout] 60 | /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 60 - /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] 60 + /// This allows custom providers with non-standard endpoints (e.g., `VolcEngine` ARK uses
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:71:60
[INFO] [stdout] |
[INFO] [stdout] 71 | /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 71 - /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] 71 + /// Build the full URL for responses API, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/compatible.rs:170:37
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: ResponsesResponse) -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] = note: `#[warn(clippy::needless_pass_by_value)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: &ResponsesResponse) -> Option {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/gemini.rs:141:26
[INFO] [stdout] |
[INFO] [stdout] 141 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 141 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 141 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/ollama.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 48 - .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] 48 + .timeout(std::time::Duration::from_mins(5)) // Ollama runs locally, may be slow
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openai.rs:57:26
[INFO] [stdout] |
[INFO] [stdout] 57 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 57 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 57 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openai.rs:65:5
[INFO] [stdout] |
[INFO] [stdout] 65 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 66 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 67 | | tracker.add(&TokenUsage {
[INFO] [stdout] 68 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 73 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 65 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 65 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openrouter.rs:77:26
[INFO] [stdout] |
[INFO] [stdout] 77 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 77 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 77 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openrouter.rs:85:5
[INFO] [stdout] |
[INFO] [stdout] 85 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 86 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 87 | | tracker.add(&TokenUsage {
[INFO] [stdout] 88 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 93 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 85 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 85 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:32:62
[INFO] [stdout] |
[INFO] [stdout] 32 | /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 32 - /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] 32 + /// `routes` maps hint names to Route structs containing `provider_name` and model.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/providers/router.rs:50:17
[INFO] [stdout] |
[INFO] [stdout] 50 | / match index {
[INFO] [stdout] 51 | | Some(i) => Some((hint, (i, route.model))),
[INFO] [stdout] 52 | | None => {
[INFO] [stdout] 53 | | tracing::warn!(
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | }
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 50 ~ if let Some(i) = index { Some((hint, (i, route.model))) } else {
[INFO] [stdout] 51 + tracing::warn!(
[INFO] [stdout] 52 + hint = hint,
[INFO] [stdout] 53 + provider = route.provider_name,
[INFO] [stdout] 54 + "Route references unknown provider, skipping"
[INFO] [stdout] 55 + );
[INFO] [stdout] 56 + None
[INFO] [stdout] 57 + }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:72:51
[INFO] [stdout] |
[INFO] [stdout] 72 | /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 72 - /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] 72 + /// Resolve a model parameter to a (provider, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:41
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (`provider_index`, actual_model) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:57
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (provider_index, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:122:22
[INFO] [stdout] |
[INFO] [stdout] 122 | let prompt = self.prompt_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout] = note: `#[warn(clippy::cast_precision_loss)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:123:26
[INFO] [stdout] |
[INFO] [stdout] 123 | let completion = self.completion_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/traits.rs:178:25
[INFO] [stdout] |
[INFO] [stdout] 178 | let last_user = messages
[INFO] [stdout] | _________________________^
[INFO] [stdout] 179 | | .iter()
[INFO] [stdout] 180 | | .rfind(|m| m.role == "user")
[INFO] [stdout] 181 | | .map(|m| m.content.as_str())
[INFO] [stdout] 182 | | .unwrap_or("");
[INFO] [stdout] | |__________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 181 - .map(|m| m.content.as_str())
[INFO] [stdout] 182 - .unwrap_or("");
[INFO] [stdout] 181 + .map_or("", |m| m.content.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this loop could be written as a `while let` loop
[INFO] [stdout] --> src/providers/mod.rs:44:9
[INFO] [stdout] |
[INFO] [stdout] 44 | / loop {
[INFO] [stdout] 45 | | let Some(rel) = scrubbed[search_from..].find(prefix) else {
[INFO] [stdout] 46 | | break;
[INFO] [stdout] 47 | | };
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | search_from = start + "[REDACTED]".len();
[INFO] [stdout] 61 | | }
[INFO] [stdout] | |_________^ help: try: `while let Some(rel) = scrubbed[search_from..].find(prefix) { .. }`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop
[INFO] [stdout] = note: `#[warn(clippy::while_let_loop)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/mod.rs:321:14
[INFO] [stdout] |
[INFO] [stdout] 321 | /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 321 - /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] 321 + /// Create a `RouterProvider` if model routes are configured, otherwise return a
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: use of bitwise operator instead of lazy operator between booleans
[INFO] [stdout] --> src/security/pairing.rs:240:5
[INFO] [stdout] |
[INFO] [stdout] 240 | (len_diff == 0) & (byte_diff == 0)
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(len_diff == 0) && (byte_diff == 0)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bitwise_bool
[INFO] [stdout] = note: `#[warn(clippy::needless_bitwise_bool)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 48 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 48 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:62:26
[INFO] [stdout] |
[INFO] [stdout] 62 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 62 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 62 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (104/100)
[INFO] [stdout] --> src/security/policy.rs:172:5
[INFO] [stdout] |
[INFO] [stdout] 172 | pub fn command_risk_level(&self, command: &str) -> CommandRiskLevel {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/security/policy.rs:201:47
[INFO] [stdout] |
[INFO] [stdout] 201 | let args: Vec = words.map(|w| w.to_ascii_lowercase()).collect();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `str::to_ascii_lowercase`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/session.rs:79:43
[INFO] [stdout] |
[INFO] [stdout] 79 | /// Update an existing session (preserves created_at).
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 79 - /// Update an existing session (preserves created_at).
[INFO] [stdout] 79 + /// Update an existing session (preserves `created_at`).
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/session.rs:128:12
[INFO] [stdout] |
[INFO] [stdout] 128 | if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_none_or` instead
[INFO] [stdout] |
[INFO] [stdout] 128 - if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] 128 + if path.extension().is_none_or(|e| e != "json") {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/tools/browser.rs:114:9
[INFO] [stdout] |
[INFO] [stdout] 114 | / Command::new("agent-browser")
[INFO] [stdout] 115 | | .arg("--version")
[INFO] [stdout] 116 | | .stdout(Stdio::null())
[INFO] [stdout] 117 | | .stderr(Stdio::null())
[INFO] [stdout] ... |
[INFO] [stdout] 120 | | .map(|s| s.success())
[INFO] [stdout] 121 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 120 - .map(|s| s.success())
[INFO] [stdout] 121 - .unwrap_or(false)
[INFO] [stdout] 120 + .is_ok_and(|s| s.success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/tools/composio.rs:28:26
[INFO] [stdout] |
[INFO] [stdout] 28 | .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 28 - .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] 28 + .timeout(std::time::Duration::from_mins(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/tools/file_patch.rs:7:31
[INFO] [stdout] |
[INFO] [stdout] 7 | /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 7 - /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] 7 + /// Targeted file editing via `old_string/new_string` replacement
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/file_read.rs:82:9
[INFO] [stdout] |
[INFO] [stdout] 82 | const MAX_FILE_SIZE: u64 = 10 * 1024 * 1024;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout] = note: `#[warn(clippy::items_after_statements)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/search_files.rs:102:9
[INFO] [stdout] |
[INFO] [stdout] 102 | const MAX_MATCHES: usize = 100;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map(..).flatten()` on `Option`
[INFO] [stdout] --> src/tools/search_files.rs:98:36
[INFO] [stdout] |
[INFO] [stdout] 98 | let glob_pat = glob_filter.map(|g| glob::Pattern::new(g).ok()).flatten();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try replacing `map` with `and_then` and remove the `.flatten()`: `and_then(|g| glob::Pattern::new(g).ok())`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten
[INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/tools/search_files.rs:128:1
[INFO] [stdout] |
[INFO] [stdout] 128 | / async fn search_recursive(
[INFO] [stdout] 129 | | dir: &std::path::Path,
[INFO] [stdout] 130 | | re: ®ex::Regex,
[INFO] [stdout] 131 | | glob_pat: &Option,
[INFO] [stdout] ... |
[INFO] [stdout] 187 | | }
[INFO] [stdout] | |_^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 131 - glob_pat: &Option,
[INFO] [stdout] 131 + glob_pat: Option<&glob::Pattern>,
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/tools/search_files.rs:136:5
[INFO] [stdout] |
[INFO] [stdout] 136 | / let mut entries = match tokio::fs::read_dir(dir).await {
[INFO] [stdout] 137 | | Ok(e) => e,
[INFO] [stdout] 138 | | Err(_) => return,
[INFO] [stdout] 139 | | };
[INFO] [stdout] | |______^ help: consider writing: `let Ok(mut entries) = tokio::fs::read_dir(dir).await else { return };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout] = note: `#[warn(clippy::manual_let_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tools/shell.rs:66:23
[INFO] [stdout] |
[INFO] [stdout] 66 | .and_then(|v| v.as_bool())
[INFO] [stdout] | ^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_bool`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (103/100)
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] 91 | | ) -> Result<()> {
[INFO] [stdout] | |___________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:135:29
[INFO] [stdout] |
[INFO] [stdout] 135 | / ... if !self.input.trim().is_empty() {
[INFO] [stdout] 136 | | ... let user_msg = self.input.clone();
[INFO] [stdout] 137 | | ... self.input.clear();
[INFO] [stdout] 138 | | ... self.cursor_pos = 0;
[INFO] [stdout] ... |
[INFO] [stdout] 176 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 134 ~ (KeyCode::Enter, _) if !agent_running
[INFO] [stdout] 135 ~ && !self.input.trim().is_empty() => {
[INFO] [stdout] 136 | let user_msg = self.input.clone();
[INFO] [stdout] ...
[INFO] [stdout] 175 | }
[INFO] [stdout] 176 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:183:29
[INFO] [stdout] |
[INFO] [stdout] 183 | / ... if self.cursor_pos > 0 {
[INFO] [stdout] 184 | | ... self.cursor_pos -= 1;
[INFO] [stdout] 185 | | ... self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 182 ~ (KeyCode::Backspace, _) if !agent_running
[INFO] [stdout] 183 ~ && self.cursor_pos > 0 => {
[INFO] [stdout] 184 | self.cursor_pos -= 1;
[INFO] [stdout] 185 | self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:192:29
[INFO] [stdout] |
[INFO] [stdout] 192 | / ... if self.cursor_pos < self.input.len() {
[INFO] [stdout] 193 | | ... self.cursor_pos += 1;
[INFO] [stdout] 194 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 191 ~ (KeyCode::Right, _) if !agent_running
[INFO] [stdout] 192 ~ && self.cursor_pos < self.input.len() => {
[INFO] [stdout] 193 | self.cursor_pos += 1;
[INFO] [stdout] 194 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:327:27
[INFO] [stdout] |
[INFO] [stdout] 327 | let total_lines = lines.len() as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_truncation)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 327 - let total_lines = lines.len() as u16;
[INFO] [stdout] 327 + let total_lines = u16::try_from(lines.len());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (107/100)
[INFO] [stdout] --> src/tui/app.rs:373:5
[INFO] [stdout] |
[INFO] [stdout] 373 | / fn handle_slash_command(
[INFO] [stdout] 374 | | &mut self,
[INFO] [stdout] 375 | | cmd: &str,
[INFO] [stdout] 376 | | agent_opt: &mut Option,
[INFO] [stdout] 377 | | ) -> Option {
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:424:29
[INFO] [stdout] |
[INFO] [stdout] 424 | let model = agent_opt
[INFO] [stdout] | _____________________________^
[INFO] [stdout] 425 | | .as_ref()
[INFO] [stdout] 426 | | .map(|a| a.model.as_str())
[INFO] [stdout] 427 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 426 - .map(|a| a.model.as_str())
[INFO] [stdout] 427 - .unwrap_or("unknown");
[INFO] [stdout] 426 + .map_or("unknown", |a| a.model.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:431:26
[INFO] [stdout] |
[INFO] [stdout] 431 | let id = agent_opt
[INFO] [stdout] | __________________________^
[INFO] [stdout] 432 | | .as_ref()
[INFO] [stdout] 433 | | .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 433 - .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 - .unwrap_or("unknown");
[INFO] [stdout] 433 + .map_or("unknown", |a| a.session_id.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:446:33
[INFO] [stdout] |
[INFO] [stdout] 446 | / ... out.push_str(&format!(
[INFO] [stdout] 447 | | ... " {} ({} msgs) - {}\n",
[INFO] [stdout] 448 | | ... s.id, s.message_count, s.preview
[INFO] [stdout] 449 | | ... ));
[INFO] [stdout] | |________________________^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] = note: `#[warn(clippy::format_push_string)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 446 ~ let _ = write!(out, " {} ({} msgs) - {}\n",
[INFO] [stdout] 447 ~ s.id, s.message_count, s.preview);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:472:25
[INFO] [stdout] |
[INFO] [stdout] 472 | content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 472 - content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] 472 + let _ = write!(content, "{label}: {}\n\n", msg.content);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:503:37
[INFO] [stdout] |
[INFO] [stdout] 503 | let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 503 - let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] 503 + let cursor_x = area.x + 1 + u16::try_from(self.cursor_pos);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tui/mod.rs:276:49
[INFO] [stdout] |
[INFO] [stdout] 276 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/tui/mod.rs:341:55
[INFO] [stdout] |
[INFO] [stdout] 341 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 341 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 341 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/tui/mod.rs:424:22
[INFO] [stdout] |
[INFO] [stdout] 424 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 424 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 424 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/tui/mod.rs:433:17
[INFO] [stdout] |
[INFO] [stdout] 433 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/skillforge/mod.rs:1:5
[INFO] [stdout] |
[INFO] [stdout] 1 | //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] 1 + //! `SkillForge` — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:124:28
[INFO] [stdout] |
[INFO] [stdout] 124 | fn score_compatibility(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout] = note: `#[warn(clippy::unused_self)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:134:22
[INFO] [stdout] |
[INFO] [stdout] 134 | fn score_quality(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/skillforge/evaluate.rs:136:20
[INFO] [stdout] |
[INFO] [stdout] 136 | let raw = ((c.stars as f64) + 1.0).log2() / 10.0;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:141:23
[INFO] [stdout] |
[INFO] [stdout] 141 | fn score_security(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:56:22
[INFO] [stdout] |
[INFO] [stdout] 56 | fn generate_toml(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or_else()` on an `Option` value
[INFO] [stdout] --> src/skillforge/integrate.rs:58:23
[INFO] [stdout] |
[INFO] [stdout] 58 | let updated = c
[INFO] [stdout] | _______________________^
[INFO] [stdout] 59 | | .updated_at
[INFO] [stdout] 60 | | .map(|d| d.format("%Y-%m-%d").to_string())
[INFO] [stdout] 61 | | .unwrap_or_else(|| "unknown".into());
[INFO] [stdout] | |________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 58 ~ let updated = c
[INFO] [stdout] 59 ~ .updated_at.map_or_else(|| "unknown".into(), |d| d.format("%Y-%m-%d").to_string());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:96:20
[INFO] [stdout] |
[INFO] [stdout] 96 | fn generate_md(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/skillforge/integrate.rs:165:9
[INFO] [stdout] |
[INFO] [stdout] 165 | bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 165 - bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] 165 + bail!("Skill name '{name}' is unsafe as a path component");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/skillforge/scout.rs:76:23
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option) -> Self {
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option<&String>) -> Self {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/skillforge/scout.rs:108:9
[INFO] [stdout] |
[INFO] [stdout] 108 | / let items = match body.get("items").and_then(|v| v.as_array()) {
[INFO] [stdout] 109 | | Some(arr) => arr,
[INFO] [stdout] 110 | | None => return vec![],
[INFO] [stdout] 111 | | };
[INFO] [stdout] | |__________^ help: consider writing: `let Some(items) = body.get("items").and_then(|v| v.as_array()) else { return vec![] };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/skillforge/scout.rs:125:31
[INFO] [stdout] |
[INFO] [stdout] 125 | .and_then(|v| v.as_u64())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_u64`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on an `Option` value
[INFO] [stdout] --> src/skillforge/scout.rs:141:35
[INFO] [stdout] |
[INFO] [stdout] 141 | let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_some_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 141 - let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] 141 + let has_license = item.get("license").is_some_and(|v| !v.is_null());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `async` for function with no await statements
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] ... |
[INFO] [stdout] 210 | | Ok(())
[INFO] [stdout] 211 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: consider removing the `async` from this function
[INFO] [stdout] note: `await` used in an async block, which does not require the enclosing function to be `async`
[INFO] [stdout] --> src/tui/app.rs:172:75
[INFO] [stdout] |
[INFO] [stdout] 172 | ... ag.handle_message(&user_msg, &tx).await;
[INFO] [stdout] | ^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_async
[INFO] [stdout] = note: `#[warn(clippy::unused_async)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/agent/loop_.rs:27:22
[INFO] [stdout] |
[INFO] [stdout] 27 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/lib.rs:1:9
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_map_or)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 27 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 27 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/agent/loop_.rs:38:17
[INFO] [stdout] |
[INFO] [stdout] 38 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout] = note: `#[warn(clippy::bool_to_int_with_if)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/agent/loop_.rs:63:49
[INFO] [stdout] |
[INFO] [stdout] 63 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout] = note: `#[warn(clippy::redundant_closure_for_method_calls)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/agent/loop_.rs:195:10
[INFO] [stdout] |
[INFO] [stdout] 195 | /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] = note: `#[warn(clippy::doc_markdown)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 195 - /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] 195 + /// Uses `tokio::spawn` with Arc-wrapped tools for true parallelism.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:210:51
[INFO] [stdout] |
[INFO] [stdout] 210 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 210 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 210 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:242:51
[INFO] [stdout] |
[INFO] [stdout] 242 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 242 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 242 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/discord.rs:352:9
[INFO] [stdout] |
[INFO] [stdout] 352 | / self.client
[INFO] [stdout] 353 | | .get("https://discord.com/api/v10/users/@me")
[INFO] [stdout] 354 | | .header("Authorization", format!("Bot {}", self.bot_token))
[INFO] [stdout] 355 | | .send()
[INFO] [stdout] 356 | | .await
[INFO] [stdout] 357 | | .map(|r| r.status().is_success())
[INFO] [stdout] 358 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] = note: `#[warn(clippy::map_unwrap_or)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 357 - .map(|r| r.status().is_success())
[INFO] [stdout] 358 - .unwrap_or(false)
[INFO] [stdout] 357 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/irc.rs:13:43
[INFO] [stdout] |
[INFO] [stdout] 13 | const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] = note: `#[warn(clippy::duration_suboptimal_units)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 13 - const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] 13 + const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_mins(5);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:432:21
[INFO] [stdout] |
[INFO] [stdout] 432 | / if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) {
[INFO] [stdout] 433 | | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] 434 | | // CAP * ACK :sasl — server accepted, start SASL auth
[INFO] [stdout] 435 | | let mut guard = self.writer.lock().await;
[INFO] [stdout] ... |
[INFO] [stdout] 450 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 431 ~ "CAP"
[INFO] [stdout] 432 ~ if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) => {
[INFO] [stdout] 433 | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] ...
[INFO] [stdout] 449 | }
[INFO] [stdout] 450 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:455:21
[INFO] [stdout] |
[INFO] [stdout] 455 | / if sasl_pending && msg.params.first().is_some_and(|p| p == "+") {
[INFO] [stdout] 456 | | let encoded = encode_sasl_plain(
[INFO] [stdout] 457 | | ¤t_nick,
[INFO] [stdout] 458 | | self.sasl_password.as_deref().unwrap_or(""),
[INFO] [stdout] ... |
[INFO] [stdout] 464 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 453 ~ "AUTHENTICATE"
[INFO] [stdout] 454 | // Server sends "AUTHENTICATE +" to request credentials
[INFO] [stdout] 455 ~ if sasl_pending && msg.params.first().is_some_and(|p| p == "+") => {
[INFO] [stdout] 456 | let encoded = encode_sasl_plain(
[INFO] [stdout] ...
[INFO] [stdout] 463 | }
[INFO] [stdout] 464 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/slack.rs:182:9
[INFO] [stdout] |
[INFO] [stdout] 182 | / self.client
[INFO] [stdout] 183 | | .get("https://slack.com/api/auth.test")
[INFO] [stdout] 184 | | .bearer_auth(&self.bot_token)
[INFO] [stdout] 185 | | .send()
[INFO] [stdout] 186 | | .await
[INFO] [stdout] 187 | | .map(|r| r.status().is_success())
[INFO] [stdout] 188 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 187 - .map(|r| r.status().is_success())
[INFO] [stdout] 188 - .unwrap_or(false)
[INFO] [stdout] 187 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/telegram.rs:412:13
[INFO] [stdout] |
[INFO] [stdout] 412 | / anyhow::bail!(
[INFO] [stdout] 413 | | "Telegram sendMessage failed (markdown {}: {}; plain {}: {})",
[INFO] [stdout] 414 | | markdown_status,
[INFO] [stdout] 415 | | markdown_err,
[INFO] [stdout] 416 | | plain_status,
[INFO] [stdout] 417 | | plain_err
[INFO] [stdout] 418 | | );
[INFO] [stdout] | |_____________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] = note: `#[warn(clippy::uninlined_format_args)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/telegram.rs:534:9
[INFO] [stdout] |
[INFO] [stdout] 534 | / self.client
[INFO] [stdout] 535 | | .get(self.api_url("getMe"))
[INFO] [stdout] 536 | | .send()
[INFO] [stdout] 537 | | .await
[INFO] [stdout] 538 | | .map(|r| r.status().is_success())
[INFO] [stdout] 539 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 538 - .map(|r| r.status().is_success())
[INFO] [stdout] 539 - .unwrap_or(false)
[INFO] [stdout] 538 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/whatsapp.rs:192:32
[INFO] [stdout] |
[INFO] [stdout] 192 | tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 192 - tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] 192 + tokio::time::sleep(std::time::Duration::from_hours(1)).await;
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/whatsapp.rs:200:9
[INFO] [stdout] |
[INFO] [stdout] 200 | / self.client
[INFO] [stdout] 201 | | .get(&url)
[INFO] [stdout] 202 | | .header("Authorization", format!("Bearer {}", self.access_token))
[INFO] [stdout] 203 | | .send()
[INFO] [stdout] 204 | | .await
[INFO] [stdout] 205 | | .map(|r| r.status().is_success())
[INFO] [stdout] 206 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 205 - .map(|r| r.status().is_success())
[INFO] [stdout] 206 - .unwrap_or(false)
[INFO] [stdout] 205 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/channels/mod.rs:97:10
[INFO] [stdout] |
[INFO] [stdout] 97 | /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 97 - /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] 97 + /// Load `OpenClaw` format bootstrap files into the prompt.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/channels/mod.rs:276:17
[INFO] [stdout] |
[INFO] [stdout] 276 | / trimmed
[INFO] [stdout] 277 | | .char_indices()
[INFO] [stdout] 278 | | .nth(BOOTSTRAP_MAX_CHARS)
[INFO] [stdout] 279 | | .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 | | .unwrap_or(trimmed)
[INFO] [stdout] | |_______________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 279 - .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 - .unwrap_or(trimmed)
[INFO] [stdout] 279 + .map_or(trimmed, |(idx, _)| &trimmed[..idx])
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (113/100)
[INFO] [stdout] --> src/channels/mod.rs:365:1
[INFO] [stdout] |
[INFO] [stdout] 365 | pub async fn doctor_channels(config: Config) -> Result<()> {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout] = note: `#[warn(clippy::too_many_lines)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/mod.rs:756:35
[INFO] [stdout] |
[INFO] [stdout] 756 | let timeout_msg = format!(
[INFO] [stdout] | ___________________________________^
[INFO] [stdout] 757 | | "LLM response timed out after {}s",
[INFO] [stdout] 758 | | CHANNEL_MESSAGE_TIMEOUT_SECS
[INFO] [stdout] 759 | | );
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/config/schema.rs:332:30
[INFO] [stdout] |
[INFO] [stdout] 332 | /// OTLP endpoint (e.g. "http://localhost:4318"). Only used when backend = "otel".
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:336:38
[INFO] [stdout] |
[INFO] [stdout] 336 | /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 336 - /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] 336 + /// Service name reported to the `OTel` collector. Defaults to "tinyclaw".
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:474:1
[INFO] [stdout] |
[INFO] [stdout] 474 | fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_wraps)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 474 - fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] 474 + fn default_docker_memory_limit_mb() -> u64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 475 - Some(512)
[INFO] [stdout] 475 + 512
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:478:1
[INFO] [stdout] |
[INFO] [stdout] 478 | fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 478 - fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] 478 + fn default_docker_cpu_limit() -> f64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 479 - Some(1.0)
[INFO] [stdout] 479 + 1.0
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize`
[INFO] [stdout] --> src/channels/email_channel.rs:16:13
[INFO] [stdout] |
[INFO] [stdout] 16 | use serde::{Deserialize, Serialize};
[INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:794:9
[INFO] [stdout] |
[INFO] [stdout] 794 | /// NickServ IDENTIFY password
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 794 - /// NickServ IDENTIFY password
[INFO] [stdout] 794 + /// `NickServ` IDENTIFY password
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:796:30
[INFO] [stdout] |
[INFO] [stdout] 796 | /// SASL PLAIN password (IRCv3)
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 796 - /// SASL PLAIN password (IRCv3)
[INFO] [stdout] 796 + /// SASL PLAIN password (`IRCv3`)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:904:13
[INFO] [stdout] |
[INFO] [stdout] 904 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout] = note: `#[warn(clippy::assigning_clones)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::Config { config_path: config_path.clone(), workspace_dir: tinyclaw_dir.join("workspace"), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/config/schema.rs:908:13
[INFO] [stdout] |
[INFO] [stdout] 908 | let mut config = Config::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout] = note: `#[warn(clippy::field_reassign_with_default)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/config/schema.rs:1283:9
[INFO] [stdout] |
[INFO] [stdout] 1283 | config.workspace_dir = dir.join("workspace");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::Config { workspace_dir: dir.join("workspace"), config_path: config_path.clone(), default_model: Some("model-a".into()), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/config/schema.rs:1282:9
[INFO] [stdout] |
[INFO] [stdout] 1282 | let mut config = Config::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: case-sensitive file extension comparison
[INFO] [stdout] --> src/config/schema.rs:1301:42
[INFO] [stdout] |
[INFO] [stdout] 1301 | assert!(!names.iter().any(|name| name.ends_with(".bak")));
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider using a case-insensitive comparison instead
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#case_sensitive_file_extension_comparisons
[INFO] [stdout] = note: `#[warn(clippy::case_sensitive_file_extension_comparisons)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: use std::path::Path
[INFO] [stdout] |
[INFO] [stdout] 1301 ~ assert!(!names.iter().any(|name| std::path::Path::new(name)
[INFO] [stdout] 1302 + .extension()
[INFO] [stdout] 1303 ~ .is_some_and(|ext| ext.eq_ignore_ascii_case("bak"))));
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused import: `TokenUsage`
[INFO] [stdout] --> src/providers/mod.rs:11:41
[INFO] [stdout] |
[INFO] [stdout] 11 | pub use traits::{ChatMessage, Provider, TokenUsage, UsageTracker};
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:1:32
[INFO] [stdout] |
[INFO] [stdout] 1 | //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] 1 + //! Identity system supporting `OpenClaw` (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:5:13
[INFO] [stdout] |
[INFO] [stdout] 5 | //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 5 - //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] 5 + //! JSON to `TinyClaw`'s system prompt format.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/identity.rs:15:23
[INFO] [stdout] |
[INFO] [stdout] 15 | /// and behavior. See https://aieos.org for the full specification.
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/skillforge/integrate.rs:99:13
[INFO] [stdout] |
[INFO] [stdout] 99 | / r#"# {name}
[INFO] [stdout] 100 | |
[INFO] [stdout] 101 | | > Auto-generated by SkillForge
[INFO] [stdout] ... |
[INFO] [stdout] 126 | | Review before enabling in production.
[INFO] [stdout] 127 | | "#,
[INFO] [stdout] | |__^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/main.rs:1:22
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::needless_raw_string_hashes)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 99 ~ r"# {name}
[INFO] [stdout] 100 |
[INFO] [stdout] ...
[INFO] [stdout] 126 | Review before enabling in production.
[INFO] [stdout] 127 ~ ",
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:214:10
[INFO] [stdout] |
[INFO] [stdout] 214 | /// with TinyClaw's agent system.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 214 - /// with TinyClaw's agent system.
[INFO] [stdout] 214 + /// with `TinyClaw`'s agent system.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (198/100)
[INFO] [stdout] --> src/identity.rs:215:1
[INFO] [stdout] |
[INFO] [stdout] 215 | pub fn aieos_to_system_prompt(identity: &AieosIdentity) -> String {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:225:25
[INFO] [stdout] |
[INFO] [stdout] 225 | let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 225 - let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] 225 + let _ = writeln!(prompt, "**Name:** {first}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:227:29
[INFO] [stdout] |
[INFO] [stdout] 227 | let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 227 - let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] 227 + let _ = writeln!(prompt, "**Full Name:** {first} {last}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:230:25
[INFO] [stdout] |
[INFO] [stdout] 230 | let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 230 - let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] 230 + let _ = writeln!(prompt, "**Name:** {full}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:234:25
[INFO] [stdout] |
[INFO] [stdout] 234 | let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 234 - let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] 234 + let _ = writeln!(prompt, "**Nickname:** {nickname}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:239:21
[INFO] [stdout] |
[INFO] [stdout] 239 | let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 239 - let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] 239 + let _ = writeln!(prompt, "**Bio:** {bio}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:243:21
[INFO] [stdout] |
[INFO] [stdout] 243 | let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 243 - let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] 243 + let _ = writeln!(prompt, "**Origin:** {origin}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:247:21
[INFO] [stdout] |
[INFO] [stdout] 247 | let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 247 - let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] 247 + let _ = writeln!(prompt, "**Residence:** {residence}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:258:21
[INFO] [stdout] |
[INFO] [stdout] 258 | let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 258 - let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] 258 + let _ = writeln!(prompt, "**MBTI:** {mbti}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:264:25
[INFO] [stdout] |
[INFO] [stdout] 264 | let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 264 - let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] 264 + let _ = writeln!(prompt, "- Openness: {o:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:267:25
[INFO] [stdout] |
[INFO] [stdout] 267 | let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 267 - let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] 267 + let _ = writeln!(prompt, "- Conscientiousness: {c:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:270:25
[INFO] [stdout] |
[INFO] [stdout] 270 | let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 270 - let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] 270 + let _ = writeln!(prompt, "- Extraversion: {e:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:273:25
[INFO] [stdout] |
[INFO] [stdout] 273 | let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 273 - let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] 273 + let _ = writeln!(prompt, "- Agreeableness: {a:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:276:25
[INFO] [stdout] |
[INFO] [stdout] 276 | let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 276 - let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] 276 + let _ = writeln!(prompt, "- Neuroticism: {n:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:284:29
[INFO] [stdout] |
[INFO] [stdout] 284 | let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 284 - let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] 284 + let _ = writeln!(prompt, "- {trait_name}: {weight:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:293:29
[INFO] [stdout] |
[INFO] [stdout] 293 | let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 293 - let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] 293 + let _ = writeln!(prompt, "- {principle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:306:21
[INFO] [stdout] |
[INFO] [stdout] 306 | let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 306 - let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] 306 + let _ = writeln!(prompt, "**Style:** {style}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:310:21
[INFO] [stdout] |
[INFO] [stdout] 310 | let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 310 - let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] 310 + let _ = writeln!(prompt, "**Formality Level:** {formality}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:317:29
[INFO] [stdout] |
[INFO] [stdout] 317 | let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 317 - let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] 317 + let _ = writeln!(prompt, "- \"{phrase}\"");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:326:29
[INFO] [stdout] |
[INFO] [stdout] 326 | let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 326 - let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] 326 + let _ = writeln!(prompt, "- {word}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:339:21
[INFO] [stdout] |
[INFO] [stdout] 339 | let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 339 - let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] 339 + let _ = writeln!(prompt, "**Core Drive:** {drive}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:346:29
[INFO] [stdout] |
[INFO] [stdout] 346 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 346 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 346 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:355:29
[INFO] [stdout] |
[INFO] [stdout] 355 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 355 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 355 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:364:29
[INFO] [stdout] |
[INFO] [stdout] 364 | let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 364 - let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] 364 + let _ = writeln!(prompt, "- {fear}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:380:29
[INFO] [stdout] |
[INFO] [stdout] 380 | let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 380 - let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] 380 + let _ = writeln!(prompt, "- {skill}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:389:29
[INFO] [stdout] |
[INFO] [stdout] 389 | let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 389 - let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] 389 + let _ = writeln!(prompt, "- {tool}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:402:21
[INFO] [stdout] |
[INFO] [stdout] 402 | let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 402 - let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] 402 + let _ = writeln!(prompt, "**Origin Story:** {story}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:409:29
[INFO] [stdout] |
[INFO] [stdout] 409 | let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 409 - let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] 409 + let _ = writeln!(prompt, "- {edu}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:415:21
[INFO] [stdout] |
[INFO] [stdout] 415 | let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 415 - let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] 415 + let _ = writeln!(prompt, "\n**Occupation:** {occupation}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:426:21
[INFO] [stdout] |
[INFO] [stdout] 426 | let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 426 - let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] 426 + let _ = writeln!(prompt, "{appearance}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:430:21
[INFO] [stdout] |
[INFO] [stdout] 430 | let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 430 - let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] 430 + let _ = writeln!(prompt, "**Avatar Description:** {avatar}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:444:29
[INFO] [stdout] |
[INFO] [stdout] 444 | let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 444 - let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] 444 + let _ = writeln!(prompt, "- {hobby}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:453:29
[INFO] [stdout] |
[INFO] [stdout] 453 | let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 453 - let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] 453 + let _ = writeln!(prompt, "- {category}: {value}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:459:21
[INFO] [stdout] |
[INFO] [stdout] 459 | let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 459 - let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] 459 + let _ = writeln!(prompt, "\n**Lifestyle:** {lifestyle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:50
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either `aieos_path` or aieos_inline is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:64
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either aieos_path or `aieos_inline` is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: strict comparison of `f32` or `f64`
[INFO] [stdout] --> src/identity.rs:537:9
[INFO] [stdout] |
[INFO] [stdout] 537 | assert_eq!(psych.ocean.unwrap().openness.unwrap(), 0.9);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#float_cmp
[INFO] [stdout] = note: `#[warn(clippy::float_cmp)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (109/100)
[INFO] [stdout] --> src/identity.rs:573:5
[INFO] [stdout] |
[INFO] [stdout] 573 | fn aieos_to_system_prompt_full() {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/hygiene.rs:333:5
[INFO] [stdout] |
[INFO] [stdout] 333 | / fs::metadata(path)
[INFO] [stdout] 334 | | .and_then(|meta| meta.modified())
[INFO] [stdout] 335 | | .map(|modified| modified < cutoff)
[INFO] [stdout] 336 | | .unwrap_or(false)
[INFO] [stdout] | |_________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 335 - .map(|modified| modified < cutoff)
[INFO] [stdout] 336 - .unwrap_or(false)
[INFO] [stdout] 335 + .is_ok_and(|modified| modified < cutoff)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/memory/sqlite.rs:133:45
[INFO] [stdout] |
[INFO] [stdout] 133 | /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 133 - /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] 133 + /// Uses SHA-256 (truncated) instead of `DefaultHasher`, which is
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/agent/loop_.rs:596:24
[INFO] [stdout] |
[INFO] [stdout] 596 | let response = r#"
[INFO] [stdout] | ________________________^
[INFO] [stdout] 597 | | not valid json
[INFO] [stdout] 598 | |
[INFO] [stdout] 599 | | Some text after."#;
[INFO] [stdout] | |__________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/main.rs:1:22
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::needless_raw_string_hashes)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 596 ~ let response = r"
[INFO] [stdout] 597 | not valid json
[INFO] [stdout] 598 |
[INFO] [stdout] 599 ~ Some text after.";
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize`
[INFO] [stdout] --> src/channels/email_channel.rs:16:13
[INFO] [stdout] |
[INFO] [stdout] 16 | use serde::{Deserialize, Serialize};
[INFO] [stdout] | ^^^^^^^^^^^ ^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/sqlite.rs:586:9
[INFO] [stdout] |
[INFO] [stdout] 586 | / self.conn
[INFO] [stdout] 587 | | .lock()
[INFO] [stdout] 588 | | .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 588 - .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 - .unwrap_or(false)
[INFO] [stdout] 588 + .is_ok_and(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/identity.rs:769:20
[INFO] [stdout] |
[INFO] [stdout] 769 | let json = r#"{}"#;
[INFO] [stdout] | ^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 769 - let json = r#"{}"#;
[INFO] [stdout] 769 + let json = r"{}";
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/observability/otel.rs:30:22
[INFO] [stdout] |
[INFO] [stdout] 30 | /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 30 - /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] 30 + /// Create a new `OTel` observer exporting to the given OTLP endpoint.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `i64` may wrap around the value
[INFO] [stdout] --> src/observability/otel.rs:186:69
[INFO] [stdout] |
[INFO] [stdout] 186 | span.set_attribute(KeyValue::new("tokens_used", *t as i64));
[INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, use `cast_signed()` instead: `(*t).cast_signed()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_wrap
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_wrap)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:266:38
[INFO] [stdout] |
[INFO] [stdout] 266 | self.tokens_used.add(*t as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*t)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:269:45
[INFO] [stdout] |
[INFO] [stdout] 269 | self.active_sessions.record(*s as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*s)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:272:41
[INFO] [stdout] |
[INFO] [stdout] 272 | self.queue_depth.record(*d as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*d)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: binding's name is too similar to existing binding
[INFO] [stdout] --> src/providers/router.rs:242:13
[INFO] [stdout] |
[INFO] [stdout] 242 | let router = RouterProvider::new(provider_list, route_list, "default-model".to_string());
[INFO] [stdout] | ^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: existing binding defined here
[INFO] [stdout] --> src/providers/router.rs:211:9
[INFO] [stdout] |
[INFO] [stdout] 211 | routes: Vec<(&str, &str, &str)>,
[INFO] [stdout] | ^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#similar_names
[INFO] [stdout] = note: `#[warn(clippy::similar_names)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused import: `TokenUsage`
[INFO] [stdout] --> src/providers/mod.rs:11:41
[INFO] [stdout] |
[INFO] [stdout] 11 | pub use traits::{ChatMessage, Provider, TokenUsage, UsageTracker};
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/onboard/wizard.rs:1733:33
[INFO] [stdout] |
[INFO] [stdout] 1733 | let port: u16 = match port_str.trim().parse() {
[INFO] [stdout] | _________________________________^
[INFO] [stdout] 1734 | | Ok(p) => p,
[INFO] [stdout] 1735 | | Err(_) => {
[INFO] [stdout] 1736 | | println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] ... |
[INFO] [stdout] 1739 | | };
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] = note: `#[warn(clippy::single_match_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1733 ~ let port: u16 = if let Ok(p) = port_str.trim().parse() { p } else {
[INFO] [stdout] 1734 ~ println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] 1735 + 6697
[INFO] [stdout] 1736 ~ };
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/anthropic.rs:85:24
[INFO] [stdout] |
[INFO] [stdout] 85 | let base_url = base_url
[INFO] [stdout] | ________________________^
[INFO] [stdout] 86 | | .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 | | .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] | |___________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 86 - .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 - .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] 86 + .map_or("https://api.anthropic.com", |u| u.trim_end_matches('/'))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/anthropic.rs:96:26
[INFO] [stdout] |
[INFO] [stdout] 96 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 96 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 96 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/compatible.rs:41:26
[INFO] [stdout] |
[INFO] [stdout] 41 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 41 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 41 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/compatible.rs:49:5
[INFO] [stdout] |
[INFO] [stdout] 49 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 50 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 51 | | tracker.add(&TokenUsage {
[INFO] [stdout] 52 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 57 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] = note: `#[warn(clippy::ref_option)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 49 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 49 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:59:63
[INFO] [stdout] |
[INFO] [stdout] 59 | /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 59 - /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] 59 + /// Build the full URL for chat completions, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:60:73
[INFO] [stdout] |
[INFO] [stdout] 60 | /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 60 - /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] 60 + /// This allows custom providers with non-standard endpoints (e.g., `VolcEngine` ARK uses
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:71:60
[INFO] [stdout] |
[INFO] [stdout] 71 | /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 71 - /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] 71 + /// Build the full URL for responses API, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary hashes around raw string literal
[INFO] [stdout] --> src/skillforge/integrate.rs:99:13
[INFO] [stdout] |
[INFO] [stdout] 99 | / r#"# {name}
[INFO] [stdout] 100 | |
[INFO] [stdout] 101 | | > Auto-generated by SkillForge
[INFO] [stdout] ... |
[INFO] [stdout] 126 | | Review before enabling in production.
[INFO] [stdout] 127 | | "#,
[INFO] [stdout] | |__^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_raw_string_hashes
[INFO] [stdout] help: remove all the hashes around the string literal
[INFO] [stdout] |
[INFO] [stdout] 99 ~ r"# {name}
[INFO] [stdout] 100 |
[INFO] [stdout] ...
[INFO] [stdout] 126 | Review before enabling in production.
[INFO] [stdout] 127 ~ ",
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/compatible.rs:170:37
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: ResponsesResponse) -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] = note: `#[warn(clippy::needless_pass_by_value)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: &ResponsesResponse) -> Option {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/gemini.rs:141:26
[INFO] [stdout] |
[INFO] [stdout] 141 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 141 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 141 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/ollama.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 48 - .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] 48 + .timeout(std::time::Duration::from_mins(5)) // Ollama runs locally, may be slow
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openai.rs:57:26
[INFO] [stdout] |
[INFO] [stdout] 57 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 57 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 57 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openai.rs:65:5
[INFO] [stdout] |
[INFO] [stdout] 65 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 66 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 67 | | tracker.add(&TokenUsage {
[INFO] [stdout] 68 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 73 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 65 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 65 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openrouter.rs:77:26
[INFO] [stdout] |
[INFO] [stdout] 77 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 77 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 77 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openrouter.rs:85:5
[INFO] [stdout] |
[INFO] [stdout] 85 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 86 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 87 | | tracker.add(&TokenUsage {
[INFO] [stdout] 88 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 93 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 85 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 85 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:32:62
[INFO] [stdout] |
[INFO] [stdout] 32 | /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 32 - /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] 32 + /// `routes` maps hint names to Route structs containing `provider_name` and model.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/providers/router.rs:50:17
[INFO] [stdout] |
[INFO] [stdout] 50 | / match index {
[INFO] [stdout] 51 | | Some(i) => Some((hint, (i, route.model))),
[INFO] [stdout] 52 | | None => {
[INFO] [stdout] 53 | | tracing::warn!(
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | }
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 50 ~ if let Some(i) = index { Some((hint, (i, route.model))) } else {
[INFO] [stdout] 51 + tracing::warn!(
[INFO] [stdout] 52 + hint = hint,
[INFO] [stdout] 53 + provider = route.provider_name,
[INFO] [stdout] 54 + "Route references unknown provider, skipping"
[INFO] [stdout] 55 + );
[INFO] [stdout] 56 + None
[INFO] [stdout] 57 + }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:72:51
[INFO] [stdout] |
[INFO] [stdout] 72 | /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 72 - /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] 72 + /// Resolve a model parameter to a (provider, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:41
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (`provider_index`, actual_model) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:57
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (provider_index, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/router.rs:210:20
[INFO] [stdout] |
[INFO] [stdout] 210 | providers: Vec<(&'static str, &'static str)>,
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider changing the type to: `&[(&'static str, &'static str)]`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/router.rs:211:17
[INFO] [stdout] |
[INFO] [stdout] 211 | routes: Vec<(&str, &str, &str)>,
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: consider changing the type to: `&[(&str, &str, &str)]`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:122:22
[INFO] [stdout] |
[INFO] [stdout] 122 | let prompt = self.prompt_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout] = note: `#[warn(clippy::cast_precision_loss)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:123:26
[INFO] [stdout] |
[INFO] [stdout] 123 | let completion = self.completion_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/traits.rs:178:25
[INFO] [stdout] |
[INFO] [stdout] 178 | let last_user = messages
[INFO] [stdout] | _________________________^
[INFO] [stdout] 179 | | .iter()
[INFO] [stdout] 180 | | .rfind(|m| m.role == "user")
[INFO] [stdout] 181 | | .map(|m| m.content.as_str())
[INFO] [stdout] 182 | | .unwrap_or("");
[INFO] [stdout] | |__________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 181 - .map(|m| m.content.as_str())
[INFO] [stdout] 182 - .unwrap_or("");
[INFO] [stdout] 181 + .map_or("", |m| m.content.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this loop could be written as a `while let` loop
[INFO] [stdout] --> src/providers/mod.rs:44:9
[INFO] [stdout] |
[INFO] [stdout] 44 | / loop {
[INFO] [stdout] 45 | | let Some(rel) = scrubbed[search_from..].find(prefix) else {
[INFO] [stdout] 46 | | break;
[INFO] [stdout] 47 | | };
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | search_from = start + "[REDACTED]".len();
[INFO] [stdout] 61 | | }
[INFO] [stdout] | |_________^ help: try: `while let Some(rel) = scrubbed[search_from..].find(prefix) { .. }`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop
[INFO] [stdout] = note: `#[warn(clippy::while_let_loop)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/mod.rs:321:14
[INFO] [stdout] |
[INFO] [stdout] 321 | /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 321 - /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] 321 + /// Create a `RouterProvider` if model routes are configured, otherwise return a
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/runtime/docker.rs:153:9
[INFO] [stdout] |
[INFO] [stdout] 153 | cfg.memory_limit_mb = Some(256);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::DockerRuntimeConfig { memory_limit_mb: Some(256), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/runtime/docker.rs:152:9
[INFO] [stdout] |
[INFO] [stdout] 152 | let mut cfg = DockerRuntimeConfig::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: use of bitwise operator instead of lazy operator between booleans
[INFO] [stdout] --> src/security/pairing.rs:240:5
[INFO] [stdout] |
[INFO] [stdout] 240 | (len_diff == 0) & (byte_diff == 0)
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(len_diff == 0) && (byte_diff == 0)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bitwise_bool
[INFO] [stdout] = note: `#[warn(clippy::needless_bitwise_bool)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: implicitly cloning a `String` by calling `to_string` on its dereferenced type
[INFO] [stdout] --> src/security/pairing.rs:280:20
[INFO] [stdout] |
[INFO] [stdout] 280 | let code = guard.pairing_code().unwrap().to_string();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `guard.pairing_code().unwrap().clone()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone
[INFO] [stdout] = note: `#[warn(clippy::implicit_clone)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: implicitly cloning a `String` by calling `to_string` on its dereferenced type
[INFO] [stdout] --> src/security/pairing.rs:346:20
[INFO] [stdout] |
[INFO] [stdout] 346 | let code = guard.pairing_code().unwrap().to_string();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `guard.pairing_code().unwrap().clone()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: implicitly cloning a `String` by calling `to_string` on its dereferenced type
[INFO] [stdout] --> src/security/pairing.rs:471:20
[INFO] [stdout] |
[INFO] [stdout] 471 | let code = guard.pairing_code().unwrap().to_string();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `guard.pairing_code().unwrap().clone()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 48 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 48 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:62:26
[INFO] [stdout] |
[INFO] [stdout] 62 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 62 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 62 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (104/100)
[INFO] [stdout] --> src/security/policy.rs:172:5
[INFO] [stdout] |
[INFO] [stdout] 172 | pub fn command_risk_level(&self, command: &str) -> CommandRiskLevel {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/security/policy.rs:201:47
[INFO] [stdout] |
[INFO] [stdout] 201 | let args: Vec = words.map(|w| w.to_ascii_lowercase()).collect();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `str::to_ascii_lowercase`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/session.rs:79:43
[INFO] [stdout] |
[INFO] [stdout] 79 | /// Update an existing session (preserves created_at).
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 79 - /// Update an existing session (preserves created_at).
[INFO] [stdout] 79 + /// Update an existing session (preserves `created_at`).
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/session.rs:128:12
[INFO] [stdout] |
[INFO] [stdout] 128 | if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_none_or` instead
[INFO] [stdout] |
[INFO] [stdout] 128 - if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] 128 + if path.extension().is_none_or(|e| e != "json") {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: the borrowed expression implements the required traits
[INFO] [stdout] --> src/session.rs:267:31
[INFO] [stdout] |
[INFO] [stdout] 267 | ChatMessage::user(&"x".repeat(200)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `"x".repeat(200)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args
[INFO] [stdout] = note: `#[warn(clippy::needless_borrows_for_generic_args)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/tools/browser.rs:114:9
[INFO] [stdout] |
[INFO] [stdout] 114 | / Command::new("agent-browser")
[INFO] [stdout] 115 | | .arg("--version")
[INFO] [stdout] 116 | | .stdout(Stdio::null())
[INFO] [stdout] 117 | | .stderr(Stdio::null())
[INFO] [stdout] ... |
[INFO] [stdout] 120 | | .map(|s| s.success())
[INFO] [stdout] 121 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 120 - .map(|s| s.success())
[INFO] [stdout] 121 - .unwrap_or(false)
[INFO] [stdout] 120 + .is_ok_and(|s| s.success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/tools/composio.rs:28:26
[INFO] [stdout] |
[INFO] [stdout] 28 | .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 28 - .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] 28 + .timeout(std::time::Duration::from_mins(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/tools/file_patch.rs:7:31
[INFO] [stdout] |
[INFO] [stdout] 7 | /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 7 - /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] 7 + /// Targeted file editing via `old_string/new_string` replacement
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/file_read.rs:82:9
[INFO] [stdout] |
[INFO] [stdout] 82 | const MAX_FILE_SIZE: u64 = 10 * 1024 * 1024;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout] = note: `#[warn(clippy::items_after_statements)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/search_files.rs:102:9
[INFO] [stdout] |
[INFO] [stdout] 102 | const MAX_MATCHES: usize = 100;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map(..).flatten()` on `Option`
[INFO] [stdout] --> src/tools/search_files.rs:98:36
[INFO] [stdout] |
[INFO] [stdout] 98 | let glob_pat = glob_filter.map(|g| glob::Pattern::new(g).ok()).flatten();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try replacing `map` with `and_then` and remove the `.flatten()`: `and_then(|g| glob::Pattern::new(g).ok())`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten
[INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/tools/search_files.rs:128:1
[INFO] [stdout] |
[INFO] [stdout] 128 | / async fn search_recursive(
[INFO] [stdout] 129 | | dir: &std::path::Path,
[INFO] [stdout] 130 | | re: ®ex::Regex,
[INFO] [stdout] 131 | | glob_pat: &Option,
[INFO] [stdout] ... |
[INFO] [stdout] 187 | | }
[INFO] [stdout] | |_^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 131 - glob_pat: &Option,
[INFO] [stdout] 131 + glob_pat: Option<&glob::Pattern>,
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/tools/search_files.rs:136:5
[INFO] [stdout] |
[INFO] [stdout] 136 | / let mut entries = match tokio::fs::read_dir(dir).await {
[INFO] [stdout] 137 | | Ok(e) => e,
[INFO] [stdout] 138 | | Err(_) => return,
[INFO] [stdout] 139 | | };
[INFO] [stdout] | |______^ help: consider writing: `let Ok(mut entries) = tokio::fs::read_dir(dir).await else { return };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout] = note: `#[warn(clippy::manual_let_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tools/shell.rs:66:23
[INFO] [stdout] |
[INFO] [stdout] 66 | .and_then(|v| v.as_bool())
[INFO] [stdout] | ^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_bool`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (103/100)
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] 91 | | ) -> Result<()> {
[INFO] [stdout] | |___________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:135:29
[INFO] [stdout] |
[INFO] [stdout] 135 | / ... if !self.input.trim().is_empty() {
[INFO] [stdout] 136 | | ... let user_msg = self.input.clone();
[INFO] [stdout] 137 | | ... self.input.clear();
[INFO] [stdout] 138 | | ... self.cursor_pos = 0;
[INFO] [stdout] ... |
[INFO] [stdout] 176 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 134 ~ (KeyCode::Enter, _) if !agent_running
[INFO] [stdout] 135 ~ && !self.input.trim().is_empty() => {
[INFO] [stdout] 136 | let user_msg = self.input.clone();
[INFO] [stdout] ...
[INFO] [stdout] 175 | }
[INFO] [stdout] 176 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:183:29
[INFO] [stdout] |
[INFO] [stdout] 183 | / ... if self.cursor_pos > 0 {
[INFO] [stdout] 184 | | ... self.cursor_pos -= 1;
[INFO] [stdout] 185 | | ... self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 182 ~ (KeyCode::Backspace, _) if !agent_running
[INFO] [stdout] 183 ~ && self.cursor_pos > 0 => {
[INFO] [stdout] 184 | self.cursor_pos -= 1;
[INFO] [stdout] 185 | self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:192:29
[INFO] [stdout] |
[INFO] [stdout] 192 | / ... if self.cursor_pos < self.input.len() {
[INFO] [stdout] 193 | | ... self.cursor_pos += 1;
[INFO] [stdout] 194 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 191 ~ (KeyCode::Right, _) if !agent_running
[INFO] [stdout] 192 ~ && self.cursor_pos < self.input.len() => {
[INFO] [stdout] 193 | self.cursor_pos += 1;
[INFO] [stdout] 194 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:327:27
[INFO] [stdout] |
[INFO] [stdout] 327 | let total_lines = lines.len() as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_truncation)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 327 - let total_lines = lines.len() as u16;
[INFO] [stdout] 327 + let total_lines = u16::try_from(lines.len());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (107/100)
[INFO] [stdout] --> src/tui/app.rs:373:5
[INFO] [stdout] |
[INFO] [stdout] 373 | / fn handle_slash_command(
[INFO] [stdout] 374 | | &mut self,
[INFO] [stdout] 375 | | cmd: &str,
[INFO] [stdout] 376 | | agent_opt: &mut Option,
[INFO] [stdout] 377 | | ) -> Option {
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:424:29
[INFO] [stdout] |
[INFO] [stdout] 424 | let model = agent_opt
[INFO] [stdout] | _____________________________^
[INFO] [stdout] 425 | | .as_ref()
[INFO] [stdout] 426 | | .map(|a| a.model.as_str())
[INFO] [stdout] 427 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 426 - .map(|a| a.model.as_str())
[INFO] [stdout] 427 - .unwrap_or("unknown");
[INFO] [stdout] 426 + .map_or("unknown", |a| a.model.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:431:26
[INFO] [stdout] |
[INFO] [stdout] 431 | let id = agent_opt
[INFO] [stdout] | __________________________^
[INFO] [stdout] 432 | | .as_ref()
[INFO] [stdout] 433 | | .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 433 - .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 - .unwrap_or("unknown");
[INFO] [stdout] 433 + .map_or("unknown", |a| a.session_id.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:446:33
[INFO] [stdout] |
[INFO] [stdout] 446 | / ... out.push_str(&format!(
[INFO] [stdout] 447 | | ... " {} ({} msgs) - {}\n",
[INFO] [stdout] 448 | | ... s.id, s.message_count, s.preview
[INFO] [stdout] 449 | | ... ));
[INFO] [stdout] | |________________________^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] = note: `#[warn(clippy::format_push_string)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 446 ~ let _ = write!(out, " {} ({} msgs) - {}\n",
[INFO] [stdout] 447 ~ s.id, s.message_count, s.preview);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:472:25
[INFO] [stdout] |
[INFO] [stdout] 472 | content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 472 - content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] 472 + let _ = write!(content, "{label}: {}\n\n", msg.content);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:503:37
[INFO] [stdout] |
[INFO] [stdout] 503 | let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 503 - let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] 503 + let cursor_x = area.x + 1 + u16::try_from(self.cursor_pos);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tui/mod.rs:276:49
[INFO] [stdout] |
[INFO] [stdout] 276 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/tui/mod.rs:341:55
[INFO] [stdout] |
[INFO] [stdout] 341 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 341 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 341 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/tui/mod.rs:424:22
[INFO] [stdout] |
[INFO] [stdout] 424 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 424 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 424 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/tui/mod.rs:433:17
[INFO] [stdout] |
[INFO] [stdout] 433 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/gateway/mod.rs:813:63
[INFO] [stdout] |
[INFO] [stdout] 813 | idempotency_store: Arc::new(IdempotencyStore::new(Duration::from_secs(300))),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 813 - idempotency_store: Arc::new(IdempotencyStore::new(Duration::from_secs(300))),
[INFO] [stdout] 813 + idempotency_store: Arc::new(IdempotencyStore::new(Duration::from_mins(5))),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/skillforge/mod.rs:1:5
[INFO] [stdout] |
[INFO] [stdout] 1 | //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] 1 + //! `SkillForge` — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:124:28
[INFO] [stdout] |
[INFO] [stdout] 124 | fn score_compatibility(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout] = note: `#[warn(clippy::unused_self)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:134:22
[INFO] [stdout] |
[INFO] [stdout] 134 | fn score_quality(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/skillforge/evaluate.rs:136:20
[INFO] [stdout] |
[INFO] [stdout] 136 | let raw = ((c.stars as f64) + 1.0).log2() / 10.0;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:141:23
[INFO] [stdout] |
[INFO] [stdout] 141 | fn score_security(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:56:22
[INFO] [stdout] |
[INFO] [stdout] 56 | fn generate_toml(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or_else()` on an `Option` value
[INFO] [stdout] --> src/skillforge/integrate.rs:58:23
[INFO] [stdout] |
[INFO] [stdout] 58 | let updated = c
[INFO] [stdout] | _______________________^
[INFO] [stdout] 59 | | .updated_at
[INFO] [stdout] 60 | | .map(|d| d.format("%Y-%m-%d").to_string())
[INFO] [stdout] 61 | | .unwrap_or_else(|| "unknown".into());
[INFO] [stdout] | |________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 58 ~ let updated = c
[INFO] [stdout] 59 ~ .updated_at.map_or_else(|| "unknown".into(), |d| d.format("%Y-%m-%d").to_string());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:96:20
[INFO] [stdout] |
[INFO] [stdout] 96 | fn generate_md(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/skillforge/integrate.rs:165:9
[INFO] [stdout] |
[INFO] [stdout] 165 | bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 165 - bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] 165 + bail!("Skill name '{name}' is unsafe as a path component");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/skillforge/scout.rs:76:23
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option) -> Self {
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option<&String>) -> Self {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/skillforge/scout.rs:108:9
[INFO] [stdout] |
[INFO] [stdout] 108 | / let items = match body.get("items").and_then(|v| v.as_array()) {
[INFO] [stdout] 109 | | Some(arr) => arr,
[INFO] [stdout] 110 | | None => return vec![],
[INFO] [stdout] 111 | | };
[INFO] [stdout] | |__________^ help: consider writing: `let Some(items) = body.get("items").and_then(|v| v.as_array()) else { return vec![] };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/skillforge/scout.rs:125:31
[INFO] [stdout] |
[INFO] [stdout] 125 | .and_then(|v| v.as_u64())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_u64`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on an `Option` value
[INFO] [stdout] --> src/skillforge/scout.rs:141:35
[INFO] [stdout] |
[INFO] [stdout] 141 | let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_some_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 141 - let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] 141 + let has_license = item.get("license").is_some_and(|v| !v.is_null());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `async` for function with no await statements
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] ... |
[INFO] [stdout] 210 | | Ok(())
[INFO] [stdout] 211 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: consider removing the `async` from this function
[INFO] [stdout] note: `await` used in an async block, which does not require the enclosing function to be `async`
[INFO] [stdout] --> src/tui/app.rs:172:75
[INFO] [stdout] |
[INFO] [stdout] 172 | ... ag.handle_message(&user_msg, &tx).await;
[INFO] [stdout] | ^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_async
[INFO] [stdout] = note: `#[warn(clippy::unused_async)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/agent/loop_.rs:27:22
[INFO] [stdout] |
[INFO] [stdout] 27 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/main.rs:1:9
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_map_or)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 27 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 27 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/agent/loop_.rs:38:17
[INFO] [stdout] |
[INFO] [stdout] 38 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout] = note: `#[warn(clippy::bool_to_int_with_if)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/agent/loop_.rs:63:49
[INFO] [stdout] |
[INFO] [stdout] 63 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout] = note: `#[warn(clippy::redundant_closure_for_method_calls)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/agent/loop_.rs:195:10
[INFO] [stdout] |
[INFO] [stdout] 195 | /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] = note: `#[warn(clippy::doc_markdown)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 195 - /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] 195 + /// Uses `tokio::spawn` with Arc-wrapped tools for true parallelism.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:210:51
[INFO] [stdout] |
[INFO] [stdout] 210 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 210 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 210 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:242:51
[INFO] [stdout] |
[INFO] [stdout] 242 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 242 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 242 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/discord.rs:352:9
[INFO] [stdout] |
[INFO] [stdout] 352 | / self.client
[INFO] [stdout] 353 | | .get("https://discord.com/api/v10/users/@me")
[INFO] [stdout] 354 | | .header("Authorization", format!("Bot {}", self.bot_token))
[INFO] [stdout] 355 | | .send()
[INFO] [stdout] 356 | | .await
[INFO] [stdout] 357 | | .map(|r| r.status().is_success())
[INFO] [stdout] 358 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] = note: `#[warn(clippy::map_unwrap_or)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 357 - .map(|r| r.status().is_success())
[INFO] [stdout] 358 - .unwrap_or(false)
[INFO] [stdout] 357 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/irc.rs:13:43
[INFO] [stdout] |
[INFO] [stdout] 13 | const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] = note: `#[warn(clippy::duration_suboptimal_units)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 13 - const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] 13 + const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_mins(5);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:432:21
[INFO] [stdout] |
[INFO] [stdout] 432 | / if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) {
[INFO] [stdout] 433 | | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] 434 | | // CAP * ACK :sasl — server accepted, start SASL auth
[INFO] [stdout] 435 | | let mut guard = self.writer.lock().await;
[INFO] [stdout] ... |
[INFO] [stdout] 450 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 431 ~ "CAP"
[INFO] [stdout] 432 ~ if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) => {
[INFO] [stdout] 433 | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] ...
[INFO] [stdout] 449 | }
[INFO] [stdout] 450 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:455:21
[INFO] [stdout] |
[INFO] [stdout] 455 | / if sasl_pending && msg.params.first().is_some_and(|p| p == "+") {
[INFO] [stdout] 456 | | let encoded = encode_sasl_plain(
[INFO] [stdout] 457 | | ¤t_nick,
[INFO] [stdout] 458 | | self.sasl_password.as_deref().unwrap_or(""),
[INFO] [stdout] ... |
[INFO] [stdout] 464 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 453 ~ "AUTHENTICATE"
[INFO] [stdout] 454 | // Server sends "AUTHENTICATE +" to request credentials
[INFO] [stdout] 455 ~ if sasl_pending && msg.params.first().is_some_and(|p| p == "+") => {
[INFO] [stdout] 456 | let encoded = encode_sasl_plain(
[INFO] [stdout] ...
[INFO] [stdout] 463 | }
[INFO] [stdout] 464 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/slack.rs:182:9
[INFO] [stdout] |
[INFO] [stdout] 182 | / self.client
[INFO] [stdout] 183 | | .get("https://slack.com/api/auth.test")
[INFO] [stdout] 184 | | .bearer_auth(&self.bot_token)
[INFO] [stdout] 185 | | .send()
[INFO] [stdout] 186 | | .await
[INFO] [stdout] 187 | | .map(|r| r.status().is_success())
[INFO] [stdout] 188 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 187 - .map(|r| r.status().is_success())
[INFO] [stdout] 188 - .unwrap_or(false)
[INFO] [stdout] 187 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/telegram.rs:412:13
[INFO] [stdout] |
[INFO] [stdout] 412 | / anyhow::bail!(
[INFO] [stdout] 413 | | "Telegram sendMessage failed (markdown {}: {}; plain {}: {})",
[INFO] [stdout] 414 | | markdown_status,
[INFO] [stdout] 415 | | markdown_err,
[INFO] [stdout] 416 | | plain_status,
[INFO] [stdout] 417 | | plain_err
[INFO] [stdout] 418 | | );
[INFO] [stdout] | |_____________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] = note: `#[warn(clippy::uninlined_format_args)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/telegram.rs:534:9
[INFO] [stdout] |
[INFO] [stdout] 534 | / self.client
[INFO] [stdout] 535 | | .get(self.api_url("getMe"))
[INFO] [stdout] 536 | | .send()
[INFO] [stdout] 537 | | .await
[INFO] [stdout] 538 | | .map(|r| r.status().is_success())
[INFO] [stdout] 539 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 538 - .map(|r| r.status().is_success())
[INFO] [stdout] 539 - .unwrap_or(false)
[INFO] [stdout] 538 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/whatsapp.rs:192:32
[INFO] [stdout] |
[INFO] [stdout] 192 | tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 192 - tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] 192 + tokio::time::sleep(std::time::Duration::from_hours(1)).await;
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/whatsapp.rs:200:9
[INFO] [stdout] |
[INFO] [stdout] 200 | / self.client
[INFO] [stdout] 201 | | .get(&url)
[INFO] [stdout] 202 | | .header("Authorization", format!("Bearer {}", self.access_token))
[INFO] [stdout] 203 | | .send()
[INFO] [stdout] 204 | | .await
[INFO] [stdout] 205 | | .map(|r| r.status().is_success())
[INFO] [stdout] 206 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 205 - .map(|r| r.status().is_success())
[INFO] [stdout] 206 - .unwrap_or(false)
[INFO] [stdout] 205 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/channels/mod.rs:97:10
[INFO] [stdout] |
[INFO] [stdout] 97 | /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 97 - /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] 97 + /// Load `OpenClaw` format bootstrap files into the prompt.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/channels/mod.rs:276:17
[INFO] [stdout] |
[INFO] [stdout] 276 | / trimmed
[INFO] [stdout] 277 | | .char_indices()
[INFO] [stdout] 278 | | .nth(BOOTSTRAP_MAX_CHARS)
[INFO] [stdout] 279 | | .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 | | .unwrap_or(trimmed)
[INFO] [stdout] | |_______________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 279 - .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 - .unwrap_or(trimmed)
[INFO] [stdout] 279 + .map_or(trimmed, |(idx, _)| &trimmed[..idx])
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (113/100)
[INFO] [stdout] --> src/channels/mod.rs:365:1
[INFO] [stdout] |
[INFO] [stdout] 365 | pub async fn doctor_channels(config: Config) -> Result<()> {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout] = note: `#[warn(clippy::too_many_lines)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/mod.rs:756:35
[INFO] [stdout] |
[INFO] [stdout] 756 | let timeout_msg = format!(
[INFO] [stdout] | ___________________________________^
[INFO] [stdout] 757 | | "LLM response timed out after {}s",
[INFO] [stdout] 758 | | CHANNEL_MESSAGE_TIMEOUT_SECS
[INFO] [stdout] 759 | | );
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/config/schema.rs:332:30
[INFO] [stdout] |
[INFO] [stdout] 332 | /// OTLP endpoint (e.g. "http://localhost:4318"). Only used when backend = "otel".
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:336:38
[INFO] [stdout] |
[INFO] [stdout] 336 | /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 336 - /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] 336 + /// Service name reported to the `OTel` collector. Defaults to "tinyclaw".
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:474:1
[INFO] [stdout] |
[INFO] [stdout] 474 | fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_wraps)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 474 - fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] 474 + fn default_docker_memory_limit_mb() -> u64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 475 - Some(512)
[INFO] [stdout] 475 + 512
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:478:1
[INFO] [stdout] |
[INFO] [stdout] 478 | fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 478 - fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] 478 + fn default_docker_cpu_limit() -> f64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 479 - Some(1.0)
[INFO] [stdout] 479 + 1.0
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:794:9
[INFO] [stdout] |
[INFO] [stdout] 794 | /// NickServ IDENTIFY password
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 794 - /// NickServ IDENTIFY password
[INFO] [stdout] 794 + /// `NickServ` IDENTIFY password
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:796:30
[INFO] [stdout] |
[INFO] [stdout] 796 | /// SASL PLAIN password (IRCv3)
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 796 - /// SASL PLAIN password (IRCv3)
[INFO] [stdout] 796 + /// SASL PLAIN password (`IRCv3`)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:904:13
[INFO] [stdout] |
[INFO] [stdout] 904 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout] = note: `#[warn(clippy::assigning_clones)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::Config { config_path: config_path.clone(), workspace_dir: tinyclaw_dir.join("workspace"), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/config/schema.rs:908:13
[INFO] [stdout] |
[INFO] [stdout] 908 | let mut config = Config::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout] = note: `#[warn(clippy::field_reassign_with_default)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:1:32
[INFO] [stdout] |
[INFO] [stdout] 1 | //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] 1 + //! Identity system supporting `OpenClaw` (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:5:13
[INFO] [stdout] |
[INFO] [stdout] 5 | //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 5 - //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] 5 + //! JSON to `TinyClaw`'s system prompt format.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/identity.rs:15:23
[INFO] [stdout] |
[INFO] [stdout] 15 | /// and behavior. See https://aieos.org for the full specification.
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:214:10
[INFO] [stdout] |
[INFO] [stdout] 214 | /// with TinyClaw's agent system.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 214 - /// with TinyClaw's agent system.
[INFO] [stdout] 214 + /// with `TinyClaw`'s agent system.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (198/100)
[INFO] [stdout] --> src/identity.rs:215:1
[INFO] [stdout] |
[INFO] [stdout] 215 | pub fn aieos_to_system_prompt(identity: &AieosIdentity) -> String {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:225:25
[INFO] [stdout] |
[INFO] [stdout] 225 | let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 225 - let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] 225 + let _ = writeln!(prompt, "**Name:** {first}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:227:29
[INFO] [stdout] |
[INFO] [stdout] 227 | let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 227 - let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] 227 + let _ = writeln!(prompt, "**Full Name:** {first} {last}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:230:25
[INFO] [stdout] |
[INFO] [stdout] 230 | let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 230 - let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] 230 + let _ = writeln!(prompt, "**Name:** {full}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:234:25
[INFO] [stdout] |
[INFO] [stdout] 234 | let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 234 - let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] 234 + let _ = writeln!(prompt, "**Nickname:** {nickname}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:239:21
[INFO] [stdout] |
[INFO] [stdout] 239 | let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 239 - let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] 239 + let _ = writeln!(prompt, "**Bio:** {bio}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:243:21
[INFO] [stdout] |
[INFO] [stdout] 243 | let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 243 - let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] 243 + let _ = writeln!(prompt, "**Origin:** {origin}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:247:21
[INFO] [stdout] |
[INFO] [stdout] 247 | let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 247 - let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] 247 + let _ = writeln!(prompt, "**Residence:** {residence}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:258:21
[INFO] [stdout] |
[INFO] [stdout] 258 | let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 258 - let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] 258 + let _ = writeln!(prompt, "**MBTI:** {mbti}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:264:25
[INFO] [stdout] |
[INFO] [stdout] 264 | let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 264 - let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] 264 + let _ = writeln!(prompt, "- Openness: {o:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:267:25
[INFO] [stdout] |
[INFO] [stdout] 267 | let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 267 - let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] 267 + let _ = writeln!(prompt, "- Conscientiousness: {c:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:270:25
[INFO] [stdout] |
[INFO] [stdout] 270 | let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 270 - let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] 270 + let _ = writeln!(prompt, "- Extraversion: {e:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:273:25
[INFO] [stdout] |
[INFO] [stdout] 273 | let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 273 - let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] 273 + let _ = writeln!(prompt, "- Agreeableness: {a:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:276:25
[INFO] [stdout] |
[INFO] [stdout] 276 | let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 276 - let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] 276 + let _ = writeln!(prompt, "- Neuroticism: {n:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:284:29
[INFO] [stdout] |
[INFO] [stdout] 284 | let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 284 - let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] 284 + let _ = writeln!(prompt, "- {trait_name}: {weight:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:293:29
[INFO] [stdout] |
[INFO] [stdout] 293 | let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 293 - let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] 293 + let _ = writeln!(prompt, "- {principle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:306:21
[INFO] [stdout] |
[INFO] [stdout] 306 | let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 306 - let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] 306 + let _ = writeln!(prompt, "**Style:** {style}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:310:21
[INFO] [stdout] |
[INFO] [stdout] 310 | let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 310 - let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] 310 + let _ = writeln!(prompt, "**Formality Level:** {formality}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:317:29
[INFO] [stdout] |
[INFO] [stdout] 317 | let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 317 - let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] 317 + let _ = writeln!(prompt, "- \"{phrase}\"");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:326:29
[INFO] [stdout] |
[INFO] [stdout] 326 | let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 326 - let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] 326 + let _ = writeln!(prompt, "- {word}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:339:21
[INFO] [stdout] |
[INFO] [stdout] 339 | let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 339 - let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] 339 + let _ = writeln!(prompt, "**Core Drive:** {drive}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:346:29
[INFO] [stdout] |
[INFO] [stdout] 346 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 346 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 346 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:355:29
[INFO] [stdout] |
[INFO] [stdout] 355 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 355 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 355 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:364:29
[INFO] [stdout] |
[INFO] [stdout] 364 | let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 364 - let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] 364 + let _ = writeln!(prompt, "- {fear}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:380:29
[INFO] [stdout] |
[INFO] [stdout] 380 | let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 380 - let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] 380 + let _ = writeln!(prompt, "- {skill}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:389:29
[INFO] [stdout] |
[INFO] [stdout] 389 | let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 389 - let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] 389 + let _ = writeln!(prompt, "- {tool}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:402:21
[INFO] [stdout] |
[INFO] [stdout] 402 | let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 402 - let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] 402 + let _ = writeln!(prompt, "**Origin Story:** {story}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:409:29
[INFO] [stdout] |
[INFO] [stdout] 409 | let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 409 - let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] 409 + let _ = writeln!(prompt, "- {edu}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:415:21
[INFO] [stdout] |
[INFO] [stdout] 415 | let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 415 - let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] 415 + let _ = writeln!(prompt, "\n**Occupation:** {occupation}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:426:21
[INFO] [stdout] |
[INFO] [stdout] 426 | let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 426 - let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] 426 + let _ = writeln!(prompt, "{appearance}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:430:21
[INFO] [stdout] |
[INFO] [stdout] 430 | let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 430 - let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] 430 + let _ = writeln!(prompt, "**Avatar Description:** {avatar}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:444:29
[INFO] [stdout] |
[INFO] [stdout] 444 | let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 444 - let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] 444 + let _ = writeln!(prompt, "- {hobby}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:453:29
[INFO] [stdout] |
[INFO] [stdout] 453 | let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 453 - let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] 453 + let _ = writeln!(prompt, "- {category}: {value}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:459:21
[INFO] [stdout] |
[INFO] [stdout] 459 | let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 459 - let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] 459 + let _ = writeln!(prompt, "\n**Lifestyle:** {lifestyle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:50
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either `aieos_path` or aieos_inline is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:64
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either aieos_path or `aieos_inline` is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/hygiene.rs:333:5
[INFO] [stdout] |
[INFO] [stdout] 333 | / fs::metadata(path)
[INFO] [stdout] 334 | | .and_then(|meta| meta.modified())
[INFO] [stdout] 335 | | .map(|modified| modified < cutoff)
[INFO] [stdout] 336 | | .unwrap_or(false)
[INFO] [stdout] | |_________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 335 - .map(|modified| modified < cutoff)
[INFO] [stdout] 336 - .unwrap_or(false)
[INFO] [stdout] 335 + .is_ok_and(|modified| modified < cutoff)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/memory/sqlite.rs:133:45
[INFO] [stdout] |
[INFO] [stdout] 133 | /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 133 - /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] 133 + /// Uses SHA-256 (truncated) instead of `DefaultHasher`, which is
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/sqlite.rs:586:9
[INFO] [stdout] |
[INFO] [stdout] 586 | / self.conn
[INFO] [stdout] 587 | | .lock()
[INFO] [stdout] 588 | | .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 588 - .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 - .unwrap_or(false)
[INFO] [stdout] 588 + .is_ok_and(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/observability/otel.rs:30:22
[INFO] [stdout] |
[INFO] [stdout] 30 | /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 30 - /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] 30 + /// Create a new `OTel` observer exporting to the given OTLP endpoint.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `i64` may wrap around the value
[INFO] [stdout] --> src/observability/otel.rs:186:69
[INFO] [stdout] |
[INFO] [stdout] 186 | span.set_attribute(KeyValue::new("tokens_used", *t as i64));
[INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, use `cast_signed()` instead: `(*t).cast_signed()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_wrap
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_wrap)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:266:38
[INFO] [stdout] |
[INFO] [stdout] 266 | self.tokens_used.add(*t as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*t)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:269:45
[INFO] [stdout] |
[INFO] [stdout] 269 | self.active_sessions.record(*s as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*s)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:272:41
[INFO] [stdout] |
[INFO] [stdout] 272 | self.queue_depth.record(*d as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*d)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/onboard/wizard.rs:1733:33
[INFO] [stdout] |
[INFO] [stdout] 1733 | let port: u16 = match port_str.trim().parse() {
[INFO] [stdout] | _________________________________^
[INFO] [stdout] 1734 | | Ok(p) => p,
[INFO] [stdout] 1735 | | Err(_) => {
[INFO] [stdout] 1736 | | println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] ... |
[INFO] [stdout] 1739 | | };
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] = note: `#[warn(clippy::single_match_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1733 ~ let port: u16 = if let Ok(p) = port_str.trim().parse() { p } else {
[INFO] [stdout] 1734 ~ println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] 1735 + 6697
[INFO] [stdout] 1736 ~ };
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/anthropic.rs:85:24
[INFO] [stdout] |
[INFO] [stdout] 85 | let base_url = base_url
[INFO] [stdout] | ________________________^
[INFO] [stdout] 86 | | .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 | | .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] | |___________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 86 - .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 - .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] 86 + .map_or("https://api.anthropic.com", |u| u.trim_end_matches('/'))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/anthropic.rs:96:26
[INFO] [stdout] |
[INFO] [stdout] 96 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 96 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 96 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/compatible.rs:41:26
[INFO] [stdout] |
[INFO] [stdout] 41 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 41 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 41 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/compatible.rs:49:5
[INFO] [stdout] |
[INFO] [stdout] 49 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 50 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 51 | | tracker.add(&TokenUsage {
[INFO] [stdout] 52 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 57 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] = note: `#[warn(clippy::ref_option)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 49 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 49 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:59:63
[INFO] [stdout] |
[INFO] [stdout] 59 | /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 59 - /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] 59 + /// Build the full URL for chat completions, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:60:73
[INFO] [stdout] |
[INFO] [stdout] 60 | /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 60 - /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] 60 + /// This allows custom providers with non-standard endpoints (e.g., `VolcEngine` ARK uses
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:71:60
[INFO] [stdout] |
[INFO] [stdout] 71 | /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 71 - /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] 71 + /// Build the full URL for responses API, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/compatible.rs:170:37
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: ResponsesResponse) -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] = note: `#[warn(clippy::needless_pass_by_value)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: &ResponsesResponse) -> Option {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/gemini.rs:141:26
[INFO] [stdout] |
[INFO] [stdout] 141 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 141 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 141 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/ollama.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 48 - .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] 48 + .timeout(std::time::Duration::from_mins(5)) // Ollama runs locally, may be slow
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openai.rs:57:26
[INFO] [stdout] |
[INFO] [stdout] 57 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 57 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 57 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openai.rs:65:5
[INFO] [stdout] |
[INFO] [stdout] 65 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 66 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 67 | | tracker.add(&TokenUsage {
[INFO] [stdout] 68 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 73 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 65 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 65 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openrouter.rs:77:26
[INFO] [stdout] |
[INFO] [stdout] 77 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 77 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 77 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openrouter.rs:85:5
[INFO] [stdout] |
[INFO] [stdout] 85 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 86 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 87 | | tracker.add(&TokenUsage {
[INFO] [stdout] 88 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 93 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 85 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 85 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:32:62
[INFO] [stdout] |
[INFO] [stdout] 32 | /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 32 - /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] 32 + /// `routes` maps hint names to Route structs containing `provider_name` and model.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/providers/router.rs:50:17
[INFO] [stdout] |
[INFO] [stdout] 50 | / match index {
[INFO] [stdout] 51 | | Some(i) => Some((hint, (i, route.model))),
[INFO] [stdout] 52 | | None => {
[INFO] [stdout] 53 | | tracing::warn!(
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | }
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 50 ~ if let Some(i) = index { Some((hint, (i, route.model))) } else {
[INFO] [stdout] 51 + tracing::warn!(
[INFO] [stdout] 52 + hint = hint,
[INFO] [stdout] 53 + provider = route.provider_name,
[INFO] [stdout] 54 + "Route references unknown provider, skipping"
[INFO] [stdout] 55 + );
[INFO] [stdout] 56 + None
[INFO] [stdout] 57 + }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:72:51
[INFO] [stdout] |
[INFO] [stdout] 72 | /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 72 - /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] 72 + /// Resolve a model parameter to a (provider, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:41
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (`provider_index`, actual_model) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:57
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (provider_index, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:122:22
[INFO] [stdout] |
[INFO] [stdout] 122 | let prompt = self.prompt_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout] = note: `#[warn(clippy::cast_precision_loss)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:123:26
[INFO] [stdout] |
[INFO] [stdout] 123 | let completion = self.completion_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/traits.rs:178:25
[INFO] [stdout] |
[INFO] [stdout] 178 | let last_user = messages
[INFO] [stdout] | _________________________^
[INFO] [stdout] 179 | | .iter()
[INFO] [stdout] 180 | | .rfind(|m| m.role == "user")
[INFO] [stdout] 181 | | .map(|m| m.content.as_str())
[INFO] [stdout] 182 | | .unwrap_or("");
[INFO] [stdout] | |__________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 181 - .map(|m| m.content.as_str())
[INFO] [stdout] 182 - .unwrap_or("");
[INFO] [stdout] 181 + .map_or("", |m| m.content.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this loop could be written as a `while let` loop
[INFO] [stdout] --> src/providers/mod.rs:44:9
[INFO] [stdout] |
[INFO] [stdout] 44 | / loop {
[INFO] [stdout] 45 | | let Some(rel) = scrubbed[search_from..].find(prefix) else {
[INFO] [stdout] 46 | | break;
[INFO] [stdout] 47 | | };
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | search_from = start + "[REDACTED]".len();
[INFO] [stdout] 61 | | }
[INFO] [stdout] | |_________^ help: try: `while let Some(rel) = scrubbed[search_from..].find(prefix) { .. }`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop
[INFO] [stdout] = note: `#[warn(clippy::while_let_loop)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/mod.rs:321:14
[INFO] [stdout] |
[INFO] [stdout] 321 | /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 321 - /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] 321 + /// Create a `RouterProvider` if model routes are configured, otherwise return a
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: use of bitwise operator instead of lazy operator between booleans
[INFO] [stdout] --> src/security/pairing.rs:240:5
[INFO] [stdout] |
[INFO] [stdout] 240 | (len_diff == 0) & (byte_diff == 0)
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(len_diff == 0) && (byte_diff == 0)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bitwise_bool
[INFO] [stdout] = note: `#[warn(clippy::needless_bitwise_bool)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 48 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 48 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:62:26
[INFO] [stdout] |
[INFO] [stdout] 62 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 62 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 62 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/security/policy.rs:172:31
[INFO] [stdout] |
[INFO] [stdout] 172 | pub fn command_risk_level(&self, command: &str) -> CommandRiskLevel {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout] = note: `#[warn(clippy::unused_self)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (104/100)
[INFO] [stdout] --> src/security/policy.rs:172:5
[INFO] [stdout] |
[INFO] [stdout] 172 | pub fn command_risk_level(&self, command: &str) -> CommandRiskLevel {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/security/policy.rs:201:47
[INFO] [stdout] |
[INFO] [stdout] 201 | let args: Vec = words.map(|w| w.to_ascii_lowercase()).collect();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `str::to_ascii_lowercase`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/session.rs:79:43
[INFO] [stdout] |
[INFO] [stdout] 79 | /// Update an existing session (preserves created_at).
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 79 - /// Update an existing session (preserves created_at).
[INFO] [stdout] 79 + /// Update an existing session (preserves `created_at`).
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/session.rs:128:12
[INFO] [stdout] |
[INFO] [stdout] 128 | if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_none_or` instead
[INFO] [stdout] |
[INFO] [stdout] 128 - if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] 128 + if path.extension().is_none_or(|e| e != "json") {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/tools/browser.rs:114:9
[INFO] [stdout] |
[INFO] [stdout] 114 | / Command::new("agent-browser")
[INFO] [stdout] 115 | | .arg("--version")
[INFO] [stdout] 116 | | .stdout(Stdio::null())
[INFO] [stdout] 117 | | .stderr(Stdio::null())
[INFO] [stdout] ... |
[INFO] [stdout] 120 | | .map(|s| s.success())
[INFO] [stdout] 121 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 120 - .map(|s| s.success())
[INFO] [stdout] 121 - .unwrap_or(false)
[INFO] [stdout] 120 + .is_ok_and(|s| s.success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/tools/composio.rs:28:26
[INFO] [stdout] |
[INFO] [stdout] 28 | .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 28 - .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] 28 + .timeout(std::time::Duration::from_mins(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/tools/file_patch.rs:7:31
[INFO] [stdout] |
[INFO] [stdout] 7 | /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 7 - /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] 7 + /// Targeted file editing via `old_string/new_string` replacement
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/file_read.rs:82:9
[INFO] [stdout] |
[INFO] [stdout] 82 | const MAX_FILE_SIZE: u64 = 10 * 1024 * 1024;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout] = note: `#[warn(clippy::items_after_statements)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/search_files.rs:102:9
[INFO] [stdout] |
[INFO] [stdout] 102 | const MAX_MATCHES: usize = 100;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map(..).flatten()` on `Option`
[INFO] [stdout] --> src/tools/search_files.rs:98:36
[INFO] [stdout] |
[INFO] [stdout] 98 | let glob_pat = glob_filter.map(|g| glob::Pattern::new(g).ok()).flatten();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try replacing `map` with `and_then` and remove the `.flatten()`: `and_then(|g| glob::Pattern::new(g).ok())`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten
[INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/tools/search_files.rs:128:1
[INFO] [stdout] |
[INFO] [stdout] 128 | / async fn search_recursive(
[INFO] [stdout] 129 | | dir: &std::path::Path,
[INFO] [stdout] 130 | | re: ®ex::Regex,
[INFO] [stdout] 131 | | glob_pat: &Option,
[INFO] [stdout] ... |
[INFO] [stdout] 187 | | }
[INFO] [stdout] | |_^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 131 - glob_pat: &Option,
[INFO] [stdout] 131 + glob_pat: Option<&glob::Pattern>,
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/tools/search_files.rs:136:5
[INFO] [stdout] |
[INFO] [stdout] 136 | / let mut entries = match tokio::fs::read_dir(dir).await {
[INFO] [stdout] 137 | | Ok(e) => e,
[INFO] [stdout] 138 | | Err(_) => return,
[INFO] [stdout] 139 | | };
[INFO] [stdout] | |______^ help: consider writing: `let Ok(mut entries) = tokio::fs::read_dir(dir).await else { return };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout] = note: `#[warn(clippy::manual_let_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tools/shell.rs:66:23
[INFO] [stdout] |
[INFO] [stdout] 66 | .and_then(|v| v.as_bool())
[INFO] [stdout] | ^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_bool`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (103/100)
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] 91 | | ) -> Result<()> {
[INFO] [stdout] | |___________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:135:29
[INFO] [stdout] |
[INFO] [stdout] 135 | / ... if !self.input.trim().is_empty() {
[INFO] [stdout] 136 | | ... let user_msg = self.input.clone();
[INFO] [stdout] 137 | | ... self.input.clear();
[INFO] [stdout] 138 | | ... self.cursor_pos = 0;
[INFO] [stdout] ... |
[INFO] [stdout] 176 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 134 ~ (KeyCode::Enter, _) if !agent_running
[INFO] [stdout] 135 ~ && !self.input.trim().is_empty() => {
[INFO] [stdout] 136 | let user_msg = self.input.clone();
[INFO] [stdout] ...
[INFO] [stdout] 175 | }
[INFO] [stdout] 176 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:183:29
[INFO] [stdout] |
[INFO] [stdout] 183 | / ... if self.cursor_pos > 0 {
[INFO] [stdout] 184 | | ... self.cursor_pos -= 1;
[INFO] [stdout] 185 | | ... self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 182 ~ (KeyCode::Backspace, _) if !agent_running
[INFO] [stdout] 183 ~ && self.cursor_pos > 0 => {
[INFO] [stdout] 184 | self.cursor_pos -= 1;
[INFO] [stdout] 185 | self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:192:29
[INFO] [stdout] |
[INFO] [stdout] 192 | / ... if self.cursor_pos < self.input.len() {
[INFO] [stdout] 193 | | ... self.cursor_pos += 1;
[INFO] [stdout] 194 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 191 ~ (KeyCode::Right, _) if !agent_running
[INFO] [stdout] 192 ~ && self.cursor_pos < self.input.len() => {
[INFO] [stdout] 193 | self.cursor_pos += 1;
[INFO] [stdout] 194 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:327:27
[INFO] [stdout] |
[INFO] [stdout] 327 | let total_lines = lines.len() as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_truncation)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 327 - let total_lines = lines.len() as u16;
[INFO] [stdout] 327 + let total_lines = u16::try_from(lines.len());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (107/100)
[INFO] [stdout] --> src/tui/app.rs:373:5
[INFO] [stdout] |
[INFO] [stdout] 373 | / fn handle_slash_command(
[INFO] [stdout] 374 | | &mut self,
[INFO] [stdout] 375 | | cmd: &str,
[INFO] [stdout] 376 | | agent_opt: &mut Option,
[INFO] [stdout] 377 | | ) -> Option {
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:424:29
[INFO] [stdout] |
[INFO] [stdout] 424 | let model = agent_opt
[INFO] [stdout] | _____________________________^
[INFO] [stdout] 425 | | .as_ref()
[INFO] [stdout] 426 | | .map(|a| a.model.as_str())
[INFO] [stdout] 427 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 426 - .map(|a| a.model.as_str())
[INFO] [stdout] 427 - .unwrap_or("unknown");
[INFO] [stdout] 426 + .map_or("unknown", |a| a.model.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:431:26
[INFO] [stdout] |
[INFO] [stdout] 431 | let id = agent_opt
[INFO] [stdout] | __________________________^
[INFO] [stdout] 432 | | .as_ref()
[INFO] [stdout] 433 | | .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 433 - .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 - .unwrap_or("unknown");
[INFO] [stdout] 433 + .map_or("unknown", |a| a.session_id.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:446:33
[INFO] [stdout] |
[INFO] [stdout] 446 | / ... out.push_str(&format!(
[INFO] [stdout] 447 | | ... " {} ({} msgs) - {}\n",
[INFO] [stdout] 448 | | ... s.id, s.message_count, s.preview
[INFO] [stdout] 449 | | ... ));
[INFO] [stdout] | |________________________^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] = note: `#[warn(clippy::format_push_string)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 446 ~ let _ = write!(out, " {} ({} msgs) - {}\n",
[INFO] [stdout] 447 ~ s.id, s.message_count, s.preview);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:472:25
[INFO] [stdout] |
[INFO] [stdout] 472 | content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 472 - content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] 472 + let _ = write!(content, "{label}: {}\n\n", msg.content);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:503:37
[INFO] [stdout] |
[INFO] [stdout] 503 | let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 503 - let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] 503 + let cursor_x = area.x + 1 + u16::try_from(self.cursor_pos);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tui/mod.rs:276:49
[INFO] [stdout] |
[INFO] [stdout] 276 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/tui/mod.rs:341:55
[INFO] [stdout] |
[INFO] [stdout] 341 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 341 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 341 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/tui/mod.rs:424:22
[INFO] [stdout] |
[INFO] [stdout] 424 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 424 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 424 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/tui/mod.rs:433:17
[INFO] [stdout] |
[INFO] [stdout] 433 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/skillforge/mod.rs:1:5
[INFO] [stdout] |
[INFO] [stdout] 1 | //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] 1 + //! `SkillForge` — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:124:28
[INFO] [stdout] |
[INFO] [stdout] 124 | fn score_compatibility(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:134:22
[INFO] [stdout] |
[INFO] [stdout] 134 | fn score_quality(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/skillforge/evaluate.rs:136:20
[INFO] [stdout] |
[INFO] [stdout] 136 | let raw = ((c.stars as f64) + 1.0).log2() / 10.0;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:141:23
[INFO] [stdout] |
[INFO] [stdout] 141 | fn score_security(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:56:22
[INFO] [stdout] |
[INFO] [stdout] 56 | fn generate_toml(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or_else()` on an `Option` value
[INFO] [stdout] --> src/skillforge/integrate.rs:58:23
[INFO] [stdout] |
[INFO] [stdout] 58 | let updated = c
[INFO] [stdout] | _______________________^
[INFO] [stdout] 59 | | .updated_at
[INFO] [stdout] 60 | | .map(|d| d.format("%Y-%m-%d").to_string())
[INFO] [stdout] 61 | | .unwrap_or_else(|| "unknown".into());
[INFO] [stdout] | |________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 58 ~ let updated = c
[INFO] [stdout] 59 ~ .updated_at.map_or_else(|| "unknown".into(), |d| d.format("%Y-%m-%d").to_string());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:96:20
[INFO] [stdout] |
[INFO] [stdout] 96 | fn generate_md(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/skillforge/integrate.rs:165:9
[INFO] [stdout] |
[INFO] [stdout] 165 | bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 165 - bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] 165 + bail!("Skill name '{name}' is unsafe as a path component");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/skillforge/scout.rs:76:23
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option) -> Self {
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option<&String>) -> Self {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/skillforge/scout.rs:108:9
[INFO] [stdout] |
[INFO] [stdout] 108 | / let items = match body.get("items").and_then(|v| v.as_array()) {
[INFO] [stdout] 109 | | Some(arr) => arr,
[INFO] [stdout] 110 | | None => return vec![],
[INFO] [stdout] 111 | | };
[INFO] [stdout] | |__________^ help: consider writing: `let Some(items) = body.get("items").and_then(|v| v.as_array()) else { return vec![] };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/skillforge/scout.rs:125:31
[INFO] [stdout] |
[INFO] [stdout] 125 | .and_then(|v| v.as_u64())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_u64`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on an `Option` value
[INFO] [stdout] --> src/skillforge/scout.rs:141:35
[INFO] [stdout] |
[INFO] [stdout] 141 | let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_some_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 141 - let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] 141 + let has_license = item.get("license").is_some_and(|v| !v.is_null());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `async` for function with no await statements
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] ... |
[INFO] [stdout] 210 | | Ok(())
[INFO] [stdout] 211 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: consider removing the `async` from this function
[INFO] [stdout] note: `await` used in an async block, which does not require the enclosing function to be `async`
[INFO] [stdout] --> src/tui/app.rs:172:75
[INFO] [stdout] |
[INFO] [stdout] 172 | ... ag.handle_message(&user_msg, &tx).await;
[INFO] [stdout] | ^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_async
[INFO] [stdout] = note: `#[warn(clippy::unused_async)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/agent/loop_.rs:27:22
[INFO] [stdout] |
[INFO] [stdout] 27 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] note: the lint level is defined here
[INFO] [stdout] --> src/main.rs:1:9
[INFO] [stdout] |
[INFO] [stdout] 1 | #![warn(clippy::all, clippy::pedantic)]
[INFO] [stdout] | ^^^^^^^^^^^
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_map_or)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 27 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 27 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/agent/loop_.rs:38:17
[INFO] [stdout] |
[INFO] [stdout] 38 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout] = note: `#[warn(clippy::bool_to_int_with_if)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/agent/loop_.rs:63:49
[INFO] [stdout] |
[INFO] [stdout] 63 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout] = note: `#[warn(clippy::redundant_closure_for_method_calls)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/agent/loop_.rs:195:10
[INFO] [stdout] |
[INFO] [stdout] 195 | /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] = note: `#[warn(clippy::doc_markdown)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 195 - /// Uses tokio::spawn with Arc-wrapped tools for true parallelism.
[INFO] [stdout] 195 + /// Uses `tokio::spawn` with Arc-wrapped tools for true parallelism.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:210:51
[INFO] [stdout] |
[INFO] [stdout] 210 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_lazy_evaluations)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 210 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 210 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/agent/loop_.rs:242:51
[INFO] [stdout] |
[INFO] [stdout] 242 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 242 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 242 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/discord.rs:352:9
[INFO] [stdout] |
[INFO] [stdout] 352 | / self.client
[INFO] [stdout] 353 | | .get("https://discord.com/api/v10/users/@me")
[INFO] [stdout] 354 | | .header("Authorization", format!("Bot {}", self.bot_token))
[INFO] [stdout] 355 | | .send()
[INFO] [stdout] 356 | | .await
[INFO] [stdout] 357 | | .map(|r| r.status().is_success())
[INFO] [stdout] 358 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] = note: `#[warn(clippy::map_unwrap_or)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 357 - .map(|r| r.status().is_success())
[INFO] [stdout] 358 - .unwrap_or(false)
[INFO] [stdout] 357 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/irc.rs:13:43
[INFO] [stdout] |
[INFO] [stdout] 13 | const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] = note: `#[warn(clippy::duration_suboptimal_units)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 13 - const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300);
[INFO] [stdout] 13 + const READ_TIMEOUT: std::time::Duration = std::time::Duration::from_mins(5);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:432:21
[INFO] [stdout] |
[INFO] [stdout] 432 | / if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) {
[INFO] [stdout] 433 | | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] 434 | | // CAP * ACK :sasl — server accepted, start SASL auth
[INFO] [stdout] 435 | | let mut guard = self.writer.lock().await;
[INFO] [stdout] ... |
[INFO] [stdout] 450 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] = note: `#[warn(clippy::collapsible_match)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 431 ~ "CAP"
[INFO] [stdout] 432 ~ if sasl_pending && msg.params.iter().any(|p| p.contains("sasl")) => {
[INFO] [stdout] 433 | if msg.params.iter().any(|p| p.contains("ACK")) {
[INFO] [stdout] ...
[INFO] [stdout] 449 | }
[INFO] [stdout] 450 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/channels/irc.rs:455:21
[INFO] [stdout] |
[INFO] [stdout] 455 | / if sasl_pending && msg.params.first().is_some_and(|p| p == "+") {
[INFO] [stdout] 456 | | let encoded = encode_sasl_plain(
[INFO] [stdout] 457 | | ¤t_nick,
[INFO] [stdout] 458 | | self.sasl_password.as_deref().unwrap_or(""),
[INFO] [stdout] ... |
[INFO] [stdout] 464 | | }
[INFO] [stdout] | |_____________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 453 ~ "AUTHENTICATE"
[INFO] [stdout] 454 | // Server sends "AUTHENTICATE +" to request credentials
[INFO] [stdout] 455 ~ if sasl_pending && msg.params.first().is_some_and(|p| p == "+") => {
[INFO] [stdout] 456 | let encoded = encode_sasl_plain(
[INFO] [stdout] ...
[INFO] [stdout] 463 | }
[INFO] [stdout] 464 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/slack.rs:182:9
[INFO] [stdout] |
[INFO] [stdout] 182 | / self.client
[INFO] [stdout] 183 | | .get("https://slack.com/api/auth.test")
[INFO] [stdout] 184 | | .bearer_auth(&self.bot_token)
[INFO] [stdout] 185 | | .send()
[INFO] [stdout] 186 | | .await
[INFO] [stdout] 187 | | .map(|r| r.status().is_success())
[INFO] [stdout] 188 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 187 - .map(|r| r.status().is_success())
[INFO] [stdout] 188 - .unwrap_or(false)
[INFO] [stdout] 187 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/telegram.rs:412:13
[INFO] [stdout] |
[INFO] [stdout] 412 | / anyhow::bail!(
[INFO] [stdout] 413 | | "Telegram sendMessage failed (markdown {}: {}; plain {}: {})",
[INFO] [stdout] 414 | | markdown_status,
[INFO] [stdout] 415 | | markdown_err,
[INFO] [stdout] 416 | | plain_status,
[INFO] [stdout] 417 | | plain_err
[INFO] [stdout] 418 | | );
[INFO] [stdout] | |_____________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] = note: `#[warn(clippy::uninlined_format_args)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/telegram.rs:534:9
[INFO] [stdout] |
[INFO] [stdout] 534 | / self.client
[INFO] [stdout] 535 | | .get(self.api_url("getMe"))
[INFO] [stdout] 536 | | .send()
[INFO] [stdout] 537 | | .await
[INFO] [stdout] 538 | | .map(|r| r.status().is_success())
[INFO] [stdout] 539 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 538 - .map(|r| r.status().is_success())
[INFO] [stdout] 539 - .unwrap_or(false)
[INFO] [stdout] 538 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/channels/whatsapp.rs:192:32
[INFO] [stdout] |
[INFO] [stdout] 192 | tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 192 - tokio::time::sleep(std::time::Duration::from_secs(3600)).await;
[INFO] [stdout] 192 + tokio::time::sleep(std::time::Duration::from_hours(1)).await;
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/channels/whatsapp.rs:200:9
[INFO] [stdout] |
[INFO] [stdout] 200 | / self.client
[INFO] [stdout] 201 | | .get(&url)
[INFO] [stdout] 202 | | .header("Authorization", format!("Bearer {}", self.access_token))
[INFO] [stdout] 203 | | .send()
[INFO] [stdout] 204 | | .await
[INFO] [stdout] 205 | | .map(|r| r.status().is_success())
[INFO] [stdout] 206 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 205 - .map(|r| r.status().is_success())
[INFO] [stdout] 206 - .unwrap_or(false)
[INFO] [stdout] 205 + .is_ok_and(|r| r.status().is_success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/channels/mod.rs:97:10
[INFO] [stdout] |
[INFO] [stdout] 97 | /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 97 - /// Load OpenClaw format bootstrap files into the prompt.
[INFO] [stdout] 97 + /// Load `OpenClaw` format bootstrap files into the prompt.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/channels/mod.rs:276:17
[INFO] [stdout] |
[INFO] [stdout] 276 | / trimmed
[INFO] [stdout] 277 | | .char_indices()
[INFO] [stdout] 278 | | .nth(BOOTSTRAP_MAX_CHARS)
[INFO] [stdout] 279 | | .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 | | .unwrap_or(trimmed)
[INFO] [stdout] | |_______________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 279 - .map(|(idx, _)| &trimmed[..idx])
[INFO] [stdout] 280 - .unwrap_or(trimmed)
[INFO] [stdout] 279 + .map_or(trimmed, |(idx, _)| &trimmed[..idx])
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (113/100)
[INFO] [stdout] --> src/channels/mod.rs:365:1
[INFO] [stdout] |
[INFO] [stdout] 365 | pub async fn doctor_channels(config: Config) -> Result<()> {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout] = note: `#[warn(clippy::too_many_lines)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/channels/mod.rs:756:35
[INFO] [stdout] |
[INFO] [stdout] 756 | let timeout_msg = format!(
[INFO] [stdout] | ___________________________________^
[INFO] [stdout] 757 | | "LLM response timed out after {}s",
[INFO] [stdout] 758 | | CHANNEL_MESSAGE_TIMEOUT_SECS
[INFO] [stdout] 759 | | );
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/config/schema.rs:332:30
[INFO] [stdout] |
[INFO] [stdout] 332 | /// OTLP endpoint (e.g. "http://localhost:4318"). Only used when backend = "otel".
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:336:38
[INFO] [stdout] |
[INFO] [stdout] 336 | /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 336 - /// Service name reported to the OTel collector. Defaults to "tinyclaw".
[INFO] [stdout] 336 + /// Service name reported to the `OTel` collector. Defaults to "tinyclaw".
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:474:1
[INFO] [stdout] |
[INFO] [stdout] 474 | fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_wraps)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 474 - fn default_docker_memory_limit_mb() -> Option {
[INFO] [stdout] 474 + fn default_docker_memory_limit_mb() -> u64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 475 - Some(512)
[INFO] [stdout] 475 + 512
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function's return value is unnecessarily wrapped by `Option`
[INFO] [stdout] --> src/config/schema.rs:478:1
[INFO] [stdout] |
[INFO] [stdout] 478 | fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_wraps
[INFO] [stdout] help: remove `Option` from the return type...
[INFO] [stdout] |
[INFO] [stdout] 478 - fn default_docker_cpu_limit() -> Option {
[INFO] [stdout] 478 + fn default_docker_cpu_limit() -> f64 {
[INFO] [stdout] |
[INFO] [stdout] help: ...and then remove the surrounding `Some()` from returning expressions
[INFO] [stdout] |
[INFO] [stdout] 479 - Some(1.0)
[INFO] [stdout] 479 + 1.0
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:794:9
[INFO] [stdout] |
[INFO] [stdout] 794 | /// NickServ IDENTIFY password
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 794 - /// NickServ IDENTIFY password
[INFO] [stdout] 794 + /// `NickServ` IDENTIFY password
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/config/schema.rs:796:30
[INFO] [stdout] |
[INFO] [stdout] 796 | /// SASL PLAIN password (IRCv3)
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 796 - /// SASL PLAIN password (IRCv3)
[INFO] [stdout] 796 + /// SASL PLAIN password (`IRCv3`)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:904:13
[INFO] [stdout] |
[INFO] [stdout] 904 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout] = note: `#[warn(clippy::assigning_clones)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::Config { config_path: config_path.clone(), workspace_dir: tinyclaw_dir.join("workspace"), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/config/schema.rs:908:13
[INFO] [stdout] |
[INFO] [stdout] 908 | let mut config = Config::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout] = note: `#[warn(clippy::field_reassign_with_default)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: assigning the result of `Clone::clone()` may be inefficient
[INFO] [stdout] --> src/config/schema.rs:909:13
[INFO] [stdout] |
[INFO] [stdout] 909 | config.config_path = config_path.clone();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use `clone_from()`: `config.config_path.clone_from(&config_path)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assigning_clones
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/config/schema.rs:1283:9
[INFO] [stdout] |
[INFO] [stdout] 1283 | config.workspace_dir = dir.join("workspace");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::Config { workspace_dir: dir.join("workspace"), config_path: config_path.clone(), default_model: Some("model-a".into()), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/config/schema.rs:1282:9
[INFO] [stdout] |
[INFO] [stdout] 1282 | let mut config = Config::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: case-sensitive file extension comparison
[INFO] [stdout] --> src/config/schema.rs:1301:42
[INFO] [stdout] |
[INFO] [stdout] 1301 | assert!(!names.iter().any(|name| name.ends_with(".bak")));
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider using a case-insensitive comparison instead
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#case_sensitive_file_extension_comparisons
[INFO] [stdout] = note: `#[warn(clippy::case_sensitive_file_extension_comparisons)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: use std::path::Path
[INFO] [stdout] |
[INFO] [stdout] 1301 ~ assert!(!names.iter().any(|name| std::path::Path::new(name)
[INFO] [stdout] 1302 + .extension()
[INFO] [stdout] 1303 ~ .is_some_and(|ext| ext.eq_ignore_ascii_case("bak"))));
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:1:32
[INFO] [stdout] |
[INFO] [stdout] 1 | //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! Identity system supporting OpenClaw (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] 1 + //! Identity system supporting `OpenClaw` (markdown) and AIEOS (JSON) formats.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:5:13
[INFO] [stdout] |
[INFO] [stdout] 5 | //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 5 - //! JSON to TinyClaw's system prompt format.
[INFO] [stdout] 5 + //! JSON to `TinyClaw`'s system prompt format.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you should put bare URLs between `<`/`>` or make a proper Markdown link
[INFO] [stdout] --> src/identity.rs:15:23
[INFO] [stdout] |
[INFO] [stdout] 15 | /// and behavior. See https://aieos.org for the full specification.
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: try: ``
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:214:10
[INFO] [stdout] |
[INFO] [stdout] 214 | /// with TinyClaw's agent system.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 214 - /// with TinyClaw's agent system.
[INFO] [stdout] 214 + /// with `TinyClaw`'s agent system.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (198/100)
[INFO] [stdout] --> src/identity.rs:215:1
[INFO] [stdout] |
[INFO] [stdout] 215 | pub fn aieos_to_system_prompt(identity: &AieosIdentity) -> String {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:225:25
[INFO] [stdout] |
[INFO] [stdout] 225 | let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 225 - let _ = writeln!(prompt, "**Name:** {}", first);
[INFO] [stdout] 225 + let _ = writeln!(prompt, "**Name:** {first}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:227:29
[INFO] [stdout] |
[INFO] [stdout] 227 | let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 227 - let _ = writeln!(prompt, "**Full Name:** {} {}", first, last);
[INFO] [stdout] 227 + let _ = writeln!(prompt, "**Full Name:** {first} {last}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:230:25
[INFO] [stdout] |
[INFO] [stdout] 230 | let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 230 - let _ = writeln!(prompt, "**Name:** {}", full);
[INFO] [stdout] 230 + let _ = writeln!(prompt, "**Name:** {full}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:234:25
[INFO] [stdout] |
[INFO] [stdout] 234 | let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 234 - let _ = writeln!(prompt, "**Nickname:** {}", nickname);
[INFO] [stdout] 234 + let _ = writeln!(prompt, "**Nickname:** {nickname}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:239:21
[INFO] [stdout] |
[INFO] [stdout] 239 | let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 239 - let _ = writeln!(prompt, "**Bio:** {}", bio);
[INFO] [stdout] 239 + let _ = writeln!(prompt, "**Bio:** {bio}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:243:21
[INFO] [stdout] |
[INFO] [stdout] 243 | let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 243 - let _ = writeln!(prompt, "**Origin:** {}", origin);
[INFO] [stdout] 243 + let _ = writeln!(prompt, "**Origin:** {origin}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:247:21
[INFO] [stdout] |
[INFO] [stdout] 247 | let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 247 - let _ = writeln!(prompt, "**Residence:** {}", residence);
[INFO] [stdout] 247 + let _ = writeln!(prompt, "**Residence:** {residence}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:258:21
[INFO] [stdout] |
[INFO] [stdout] 258 | let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 258 - let _ = writeln!(prompt, "**MBTI:** {}", mbti);
[INFO] [stdout] 258 + let _ = writeln!(prompt, "**MBTI:** {mbti}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:264:25
[INFO] [stdout] |
[INFO] [stdout] 264 | let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 264 - let _ = writeln!(prompt, "- Openness: {:.2}", o);
[INFO] [stdout] 264 + let _ = writeln!(prompt, "- Openness: {o:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:267:25
[INFO] [stdout] |
[INFO] [stdout] 267 | let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 267 - let _ = writeln!(prompt, "- Conscientiousness: {:.2}", c);
[INFO] [stdout] 267 + let _ = writeln!(prompt, "- Conscientiousness: {c:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:270:25
[INFO] [stdout] |
[INFO] [stdout] 270 | let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 270 - let _ = writeln!(prompt, "- Extraversion: {:.2}", e);
[INFO] [stdout] 270 + let _ = writeln!(prompt, "- Extraversion: {e:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:273:25
[INFO] [stdout] |
[INFO] [stdout] 273 | let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 273 - let _ = writeln!(prompt, "- Agreeableness: {:.2}", a);
[INFO] [stdout] 273 + let _ = writeln!(prompt, "- Agreeableness: {a:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:276:25
[INFO] [stdout] |
[INFO] [stdout] 276 | let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 276 - let _ = writeln!(prompt, "- Neuroticism: {:.2}", n);
[INFO] [stdout] 276 + let _ = writeln!(prompt, "- Neuroticism: {n:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:284:29
[INFO] [stdout] |
[INFO] [stdout] 284 | let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 284 - let _ = writeln!(prompt, "- {}: {:.2}", trait_name, weight);
[INFO] [stdout] 284 + let _ = writeln!(prompt, "- {trait_name}: {weight:.2}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:293:29
[INFO] [stdout] |
[INFO] [stdout] 293 | let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 293 - let _ = writeln!(prompt, "- {}", principle);
[INFO] [stdout] 293 + let _ = writeln!(prompt, "- {principle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:306:21
[INFO] [stdout] |
[INFO] [stdout] 306 | let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 306 - let _ = writeln!(prompt, "**Style:** {}", style);
[INFO] [stdout] 306 + let _ = writeln!(prompt, "**Style:** {style}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:310:21
[INFO] [stdout] |
[INFO] [stdout] 310 | let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 310 - let _ = writeln!(prompt, "**Formality Level:** {}", formality);
[INFO] [stdout] 310 + let _ = writeln!(prompt, "**Formality Level:** {formality}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:317:29
[INFO] [stdout] |
[INFO] [stdout] 317 | let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 317 - let _ = writeln!(prompt, "- \"{}\"", phrase);
[INFO] [stdout] 317 + let _ = writeln!(prompt, "- \"{phrase}\"");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:326:29
[INFO] [stdout] |
[INFO] [stdout] 326 | let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 326 - let _ = writeln!(prompt, "- {}", word);
[INFO] [stdout] 326 + let _ = writeln!(prompt, "- {word}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:339:21
[INFO] [stdout] |
[INFO] [stdout] 339 | let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 339 - let _ = writeln!(prompt, "**Core Drive:** {}", drive);
[INFO] [stdout] 339 + let _ = writeln!(prompt, "**Core Drive:** {drive}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:346:29
[INFO] [stdout] |
[INFO] [stdout] 346 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 346 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 346 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:355:29
[INFO] [stdout] |
[INFO] [stdout] 355 | let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 355 - let _ = writeln!(prompt, "- {}", goal);
[INFO] [stdout] 355 + let _ = writeln!(prompt, "- {goal}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:364:29
[INFO] [stdout] |
[INFO] [stdout] 364 | let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 364 - let _ = writeln!(prompt, "- {}", fear);
[INFO] [stdout] 364 + let _ = writeln!(prompt, "- {fear}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:380:29
[INFO] [stdout] |
[INFO] [stdout] 380 | let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 380 - let _ = writeln!(prompt, "- {}", skill);
[INFO] [stdout] 380 + let _ = writeln!(prompt, "- {skill}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:389:29
[INFO] [stdout] |
[INFO] [stdout] 389 | let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 389 - let _ = writeln!(prompt, "- {}", tool);
[INFO] [stdout] 389 + let _ = writeln!(prompt, "- {tool}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:402:21
[INFO] [stdout] |
[INFO] [stdout] 402 | let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 402 - let _ = writeln!(prompt, "**Origin Story:** {}", story);
[INFO] [stdout] 402 + let _ = writeln!(prompt, "**Origin Story:** {story}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:409:29
[INFO] [stdout] |
[INFO] [stdout] 409 | let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 409 - let _ = writeln!(prompt, "- {}", edu);
[INFO] [stdout] 409 + let _ = writeln!(prompt, "- {edu}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:415:21
[INFO] [stdout] |
[INFO] [stdout] 415 | let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 415 - let _ = writeln!(prompt, "\n**Occupation:** {}", occupation);
[INFO] [stdout] 415 + let _ = writeln!(prompt, "\n**Occupation:** {occupation}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:426:21
[INFO] [stdout] |
[INFO] [stdout] 426 | let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 426 - let _ = writeln!(prompt, "{}", appearance);
[INFO] [stdout] 426 + let _ = writeln!(prompt, "{appearance}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:430:21
[INFO] [stdout] |
[INFO] [stdout] 430 | let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 430 - let _ = writeln!(prompt, "**Avatar Description:** {}", avatar);
[INFO] [stdout] 430 + let _ = writeln!(prompt, "**Avatar Description:** {avatar}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:444:29
[INFO] [stdout] |
[INFO] [stdout] 444 | let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 444 - let _ = writeln!(prompt, "- {}", hobby);
[INFO] [stdout] 444 + let _ = writeln!(prompt, "- {hobby}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:453:29
[INFO] [stdout] |
[INFO] [stdout] 453 | let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 453 - let _ = writeln!(prompt, "- {}: {}", category, value);
[INFO] [stdout] 453 + let _ = writeln!(prompt, "- {category}: {value}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/identity.rs:459:21
[INFO] [stdout] |
[INFO] [stdout] 459 | let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 459 - let _ = writeln!(prompt, "\n**Lifestyle:** {}", lifestyle);
[INFO] [stdout] 459 + let _ = writeln!(prompt, "\n**Lifestyle:** {lifestyle}");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:50
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either `aieos_path` or aieos_inline is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/identity.rs:470:64
[INFO] [stdout] |
[INFO] [stdout] 470 | /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 470 - /// Returns true if format is "aieos" and either aieos_path or aieos_inline is set.
[INFO] [stdout] 470 + /// Returns true if format is "aieos" and either aieos_path or `aieos_inline` is set.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: strict comparison of `f32` or `f64`
[INFO] [stdout] --> src/identity.rs:537:9
[INFO] [stdout] |
[INFO] [stdout] 537 | assert_eq!(psych.ocean.unwrap().openness.unwrap(), 0.9);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#float_cmp
[INFO] [stdout] = note: `#[warn(clippy::float_cmp)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (109/100)
[INFO] [stdout] --> src/identity.rs:573:5
[INFO] [stdout] |
[INFO] [stdout] 573 | fn aieos_to_system_prompt_full() {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/hygiene.rs:333:5
[INFO] [stdout] |
[INFO] [stdout] 333 | / fs::metadata(path)
[INFO] [stdout] 334 | | .and_then(|meta| meta.modified())
[INFO] [stdout] 335 | | .map(|modified| modified < cutoff)
[INFO] [stdout] 336 | | .unwrap_or(false)
[INFO] [stdout] | |_________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 335 - .map(|modified| modified < cutoff)
[INFO] [stdout] 336 - .unwrap_or(false)
[INFO] [stdout] 335 + .is_ok_and(|modified| modified < cutoff)
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/memory/sqlite.rs:133:45
[INFO] [stdout] |
[INFO] [stdout] 133 | /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 133 - /// Uses SHA-256 (truncated) instead of DefaultHasher, which is
[INFO] [stdout] 133 + /// Uses SHA-256 (truncated) instead of `DefaultHasher`, which is
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/memory/sqlite.rs:586:9
[INFO] [stdout] |
[INFO] [stdout] 586 | / self.conn
[INFO] [stdout] 587 | | .lock()
[INFO] [stdout] 588 | | .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 588 - .map(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] 589 - .unwrap_or(false)
[INFO] [stdout] 588 + .is_ok_and(|c| c.execute_batch("SELECT 1").is_ok())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/observability/otel.rs:30:22
[INFO] [stdout] |
[INFO] [stdout] 30 | /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] | ^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 30 - /// Create a new OTel observer exporting to the given OTLP endpoint.
[INFO] [stdout] 30 + /// Create a new `OTel` observer exporting to the given OTLP endpoint.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `i64` may wrap around the value
[INFO] [stdout] --> src/observability/otel.rs:186:69
[INFO] [stdout] |
[INFO] [stdout] 186 | span.set_attribute(KeyValue::new("tokens_used", *t as i64));
[INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, use `cast_signed()` instead: `(*t).cast_signed()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_wrap
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_wrap)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:266:38
[INFO] [stdout] |
[INFO] [stdout] 266 | self.tokens_used.add(*t as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*t)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:269:45
[INFO] [stdout] |
[INFO] [stdout] 269 | self.active_sessions.record(*s as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*s)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`)
[INFO] [stdout] --> src/observability/otel.rs:272:41
[INFO] [stdout] |
[INFO] [stdout] 272 | self.queue_depth.record(*d as u64, &[]);
[INFO] [stdout] | ^^^^^^^^^ help: try: `(*d)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/onboard/wizard.rs:1733:33
[INFO] [stdout] |
[INFO] [stdout] 1733 | let port: u16 = match port_str.trim().parse() {
[INFO] [stdout] | _________________________________^
[INFO] [stdout] 1734 | | Ok(p) => p,
[INFO] [stdout] 1735 | | Err(_) => {
[INFO] [stdout] 1736 | | println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] ... |
[INFO] [stdout] 1739 | | };
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] = note: `#[warn(clippy::single_match_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1733 ~ let port: u16 = if let Ok(p) = port_str.trim().parse() { p } else {
[INFO] [stdout] 1734 ~ println!(" {} Invalid port, using 6697", style("→").dim());
[INFO] [stdout] 1735 + 6697
[INFO] [stdout] 1736 ~ };
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/anthropic.rs:85:24
[INFO] [stdout] |
[INFO] [stdout] 85 | let base_url = base_url
[INFO] [stdout] | ________________________^
[INFO] [stdout] 86 | | .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 | | .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] | |___________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 86 - .map(|u| u.trim_end_matches('/'))
[INFO] [stdout] 87 - .unwrap_or("https://api.anthropic.com")
[INFO] [stdout] 86 + .map_or("https://api.anthropic.com", |u| u.trim_end_matches('/'))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/anthropic.rs:96:26
[INFO] [stdout] |
[INFO] [stdout] 96 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 96 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 96 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/compatible.rs:41:26
[INFO] [stdout] |
[INFO] [stdout] 41 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 41 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 41 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/compatible.rs:49:5
[INFO] [stdout] |
[INFO] [stdout] 49 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 50 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 51 | | tracker.add(&TokenUsage {
[INFO] [stdout] 52 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 57 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] = note: `#[warn(clippy::ref_option)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 49 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 49 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:59:63
[INFO] [stdout] |
[INFO] [stdout] 59 | /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 59 - /// Build the full URL for chat completions, detecting if base_url already includes the path.
[INFO] [stdout] 59 + /// Build the full URL for chat completions, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:60:73
[INFO] [stdout] |
[INFO] [stdout] 60 | /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 60 - /// This allows custom providers with non-standard endpoints (e.g., VolcEngine ARK uses
[INFO] [stdout] 60 + /// This allows custom providers with non-standard endpoints (e.g., `VolcEngine` ARK uses
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/compatible.rs:71:60
[INFO] [stdout] |
[INFO] [stdout] 71 | /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] | ^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 71 - /// Build the full URL for responses API, detecting if base_url already includes the path.
[INFO] [stdout] 71 + /// Build the full URL for responses API, detecting if `base_url` already includes the path.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/compatible.rs:170:37
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: ResponsesResponse) -> Option {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] = note: `#[warn(clippy::needless_pass_by_value)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 170 | fn extract_responses_text(response: &ResponsesResponse) -> Option {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/gemini.rs:141:26
[INFO] [stdout] |
[INFO] [stdout] 141 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 141 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 141 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/ollama.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 48 - .timeout(std::time::Duration::from_secs(300)) // Ollama runs locally, may be slow
[INFO] [stdout] 48 + .timeout(std::time::Duration::from_mins(5)) // Ollama runs locally, may be slow
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openai.rs:57:26
[INFO] [stdout] |
[INFO] [stdout] 57 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 57 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 57 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openai.rs:65:5
[INFO] [stdout] |
[INFO] [stdout] 65 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 66 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 67 | | tracker.add(&TokenUsage {
[INFO] [stdout] 68 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 73 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 65 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 65 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/providers/openrouter.rs:77:26
[INFO] [stdout] |
[INFO] [stdout] 77 | .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 77 - .timeout(std::time::Duration::from_secs(120))
[INFO] [stdout] 77 + .timeout(std::time::Duration::from_mins(2))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/providers/openrouter.rs:85:5
[INFO] [stdout] |
[INFO] [stdout] 85 | / fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 86 | | if let (Some(tracker), Some(u)) = (&self.usage_tracker, usage) {
[INFO] [stdout] 87 | | tracker.add(&TokenUsage {
[INFO] [stdout] 88 | | prompt_tokens: u.prompt_tokens,
[INFO] [stdout] ... |
[INFO] [stdout] 93 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 85 - fn track_usage(&self, usage: &Option) {
[INFO] [stdout] 85 + fn track_usage(&self, usage: Option<&ApiUsage>) {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:32:62
[INFO] [stdout] |
[INFO] [stdout] 32 | /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] | ^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 32 - /// `routes` maps hint names to Route structs containing provider_name and model.
[INFO] [stdout] 32 + /// `routes` maps hint names to Route structs containing `provider_name` and model.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`
[INFO] [stdout] --> src/providers/router.rs:50:17
[INFO] [stdout] |
[INFO] [stdout] 50 | / match index {
[INFO] [stdout] 51 | | Some(i) => Some((hint, (i, route.model))),
[INFO] [stdout] 52 | | None => {
[INFO] [stdout] 53 | | tracing::warn!(
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | }
[INFO] [stdout] | |_________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_match_else
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 50 ~ if let Some(i) = index { Some((hint, (i, route.model))) } else {
[INFO] [stdout] 51 + tracing::warn!(
[INFO] [stdout] 52 + hint = hint,
[INFO] [stdout] 53 + provider = route.provider_name,
[INFO] [stdout] 54 + "Route references unknown provider, skipping"
[INFO] [stdout] 55 + );
[INFO] [stdout] 56 + None
[INFO] [stdout] 57 + }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:72:51
[INFO] [stdout] |
[INFO] [stdout] 72 | /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 72 - /// Resolve a model parameter to a (provider, actual_model) pair.
[INFO] [stdout] 72 + /// Resolve a model parameter to a (provider, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:41
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (`provider_index`, actual_model) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/router.rs:76:57
[INFO] [stdout] |
[INFO] [stdout] 76 | /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] | ^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 76 - /// Resolve a model parameter to a (provider_index, actual_model) pair.
[INFO] [stdout] 76 + /// Resolve a model parameter to a (provider_index, `actual_model`) pair.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/router.rs:210:20
[INFO] [stdout] |
[INFO] [stdout] 210 | providers: Vec<(&'static str, &'static str)>,
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider changing the type to: `&[(&'static str, &'static str)]`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/providers/router.rs:211:17
[INFO] [stdout] |
[INFO] [stdout] 211 | routes: Vec<(&str, &str, &str)>,
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: consider changing the type to: `&[(&str, &str, &str)]`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:122:22
[INFO] [stdout] |
[INFO] [stdout] 122 | let prompt = self.prompt_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout] = note: `#[warn(clippy::cast_precision_loss)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/providers/traits.rs:123:26
[INFO] [stdout] |
[INFO] [stdout] 123 | let completion = self.completion_tokens.load(Ordering::Relaxed) as f64;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/providers/traits.rs:178:25
[INFO] [stdout] |
[INFO] [stdout] 178 | let last_user = messages
[INFO] [stdout] | _________________________^
[INFO] [stdout] 179 | | .iter()
[INFO] [stdout] 180 | | .rfind(|m| m.role == "user")
[INFO] [stdout] 181 | | .map(|m| m.content.as_str())
[INFO] [stdout] 182 | | .unwrap_or("");
[INFO] [stdout] | |__________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 181 - .map(|m| m.content.as_str())
[INFO] [stdout] 182 - .unwrap_or("");
[INFO] [stdout] 181 + .map_or("", |m| m.content.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this loop could be written as a `while let` loop
[INFO] [stdout] --> src/providers/mod.rs:44:9
[INFO] [stdout] |
[INFO] [stdout] 44 | / loop {
[INFO] [stdout] 45 | | let Some(rel) = scrubbed[search_from..].find(prefix) else {
[INFO] [stdout] 46 | | break;
[INFO] [stdout] 47 | | };
[INFO] [stdout] ... |
[INFO] [stdout] 60 | | search_from = start + "[REDACTED]".len();
[INFO] [stdout] 61 | | }
[INFO] [stdout] | |_________^ help: try: `while let Some(rel) = scrubbed[search_from..].find(prefix) { .. }`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#while_let_loop
[INFO] [stdout] = note: `#[warn(clippy::while_let_loop)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/providers/mod.rs:321:14
[INFO] [stdout] |
[INFO] [stdout] 321 | /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 321 - /// Create a RouterProvider if model routes are configured, otherwise return a
[INFO] [stdout] 321 + /// Create a `RouterProvider` if model routes are configured, otherwise return a
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default()
[INFO] [stdout] --> src/runtime/docker.rs:153:9
[INFO] [stdout] |
[INFO] [stdout] 153 | cfg.memory_limit_mb = Some(256);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] note: consider initializing the variable with `config::schema::DockerRuntimeConfig { memory_limit_mb: Some(256), ..Default::default() }` and removing relevant reassignments
[INFO] [stdout] --> src/runtime/docker.rs:152:9
[INFO] [stdout] |
[INFO] [stdout] 152 | let mut cfg = DockerRuntimeConfig::default();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#field_reassign_with_default
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: use of bitwise operator instead of lazy operator between booleans
[INFO] [stdout] --> src/security/pairing.rs:240:5
[INFO] [stdout] |
[INFO] [stdout] 240 | (len_diff == 0) & (byte_diff == 0)
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `(len_diff == 0) && (byte_diff == 0)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bitwise_bool
[INFO] [stdout] = note: `#[warn(clippy::needless_bitwise_bool)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: implicitly cloning a `String` by calling `to_string` on its dereferenced type
[INFO] [stdout] --> src/security/pairing.rs:280:20
[INFO] [stdout] |
[INFO] [stdout] 280 | let code = guard.pairing_code().unwrap().to_string();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `guard.pairing_code().unwrap().clone()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone
[INFO] [stdout] = note: `#[warn(clippy::implicit_clone)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: implicitly cloning a `String` by calling `to_string` on its dereferenced type
[INFO] [stdout] --> src/security/pairing.rs:346:20
[INFO] [stdout] |
[INFO] [stdout] 346 | let code = guard.pairing_code().unwrap().to_string();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `guard.pairing_code().unwrap().clone()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: implicitly cloning a `String` by calling `to_string` on its dereferenced type
[INFO] [stdout] --> src/security/pairing.rs:471:20
[INFO] [stdout] |
[INFO] [stdout] 471 | let code = guard.pairing_code().unwrap().to_string();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using: `guard.pairing_code().unwrap().clone()`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:48:26
[INFO] [stdout] |
[INFO] [stdout] 48 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 48 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 48 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/security/policy.rs:62:26
[INFO] [stdout] |
[INFO] [stdout] 62 | .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_hours
[INFO] [stdout] |
[INFO] [stdout] 62 - .checked_sub(std::time::Duration::from_secs(3600))
[INFO] [stdout] 62 + .checked_sub(std::time::Duration::from_hours(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/security/policy.rs:172:31
[INFO] [stdout] |
[INFO] [stdout] 172 | pub fn command_risk_level(&self, command: &str) -> CommandRiskLevel {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout] = note: `#[warn(clippy::unused_self)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (104/100)
[INFO] [stdout] --> src/security/policy.rs:172:5
[INFO] [stdout] |
[INFO] [stdout] 172 | pub fn command_risk_level(&self, command: &str) -> CommandRiskLevel {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/security/policy.rs:201:47
[INFO] [stdout] |
[INFO] [stdout] 201 | let args: Vec = words.map(|w| w.to_ascii_lowercase()).collect();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `str::to_ascii_lowercase`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/session.rs:79:43
[INFO] [stdout] |
[INFO] [stdout] 79 | /// Update an existing session (preserves created_at).
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 79 - /// Update an existing session (preserves created_at).
[INFO] [stdout] 79 + /// Update an existing session (preserves `created_at`).
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/session.rs:128:12
[INFO] [stdout] |
[INFO] [stdout] 128 | if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_none_or` instead
[INFO] [stdout] |
[INFO] [stdout] 128 - if path.extension().map_or(true, |e| e != "json") {
[INFO] [stdout] 128 + if path.extension().is_none_or(|e| e != "json") {
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: the borrowed expression implements the required traits
[INFO] [stdout] --> src/session.rs:267:31
[INFO] [stdout] |
[INFO] [stdout] 267 | ChatMessage::user(&"x".repeat(200)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: change this to: `"x".repeat(200)`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args
[INFO] [stdout] = note: `#[warn(clippy::needless_borrows_for_generic_args)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on a `Result` value
[INFO] [stdout] --> src/tools/browser.rs:114:9
[INFO] [stdout] |
[INFO] [stdout] 114 | / Command::new("agent-browser")
[INFO] [stdout] 115 | | .arg("--version")
[INFO] [stdout] 116 | | .stdout(Stdio::null())
[INFO] [stdout] 117 | | .stderr(Stdio::null())
[INFO] [stdout] ... |
[INFO] [stdout] 120 | | .map(|s| s.success())
[INFO] [stdout] 121 | | .unwrap_or(false)
[INFO] [stdout] | |_____________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_ok_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 120 - .map(|s| s.success())
[INFO] [stdout] 121 - .unwrap_or(false)
[INFO] [stdout] 120 + .is_ok_and(|s| s.success())
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/tools/composio.rs:28:26
[INFO] [stdout] |
[INFO] [stdout] 28 | .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 28 - .timeout(std::time::Duration::from_secs(60))
[INFO] [stdout] 28 + .timeout(std::time::Duration::from_mins(1))
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/tools/file_patch.rs:7:31
[INFO] [stdout] |
[INFO] [stdout] 7 | /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 7 - /// Targeted file editing via old_string/new_string replacement
[INFO] [stdout] 7 + /// Targeted file editing via `old_string/new_string` replacement
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/file_read.rs:82:9
[INFO] [stdout] |
[INFO] [stdout] 82 | const MAX_FILE_SIZE: u64 = 10 * 1024 * 1024;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout] = note: `#[warn(clippy::items_after_statements)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: adding items after statements is confusing, since items exist from the start of the scope
[INFO] [stdout] --> src/tools/search_files.rs:102:9
[INFO] [stdout] |
[INFO] [stdout] 102 | const MAX_MATCHES: usize = 100;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#items_after_statements
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map(..).flatten()` on `Option`
[INFO] [stdout] --> src/tools/search_files.rs:98:36
[INFO] [stdout] |
[INFO] [stdout] 98 | let glob_pat = glob_filter.map(|g| glob::Pattern::new(g).ok()).flatten();
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try replacing `map` with `and_then` and remove the `.flatten()`: `and_then(|g| glob::Pattern::new(g).ok())`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_flatten
[INFO] [stdout] = note: `#[warn(clippy::map_flatten)]` implied by `#[warn(clippy::all)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: it is more idiomatic to use `Option<&T>` instead of `&Option`
[INFO] [stdout] --> src/tools/search_files.rs:128:1
[INFO] [stdout] |
[INFO] [stdout] 128 | / async fn search_recursive(
[INFO] [stdout] 129 | | dir: &std::path::Path,
[INFO] [stdout] 130 | | re: ®ex::Regex,
[INFO] [stdout] 131 | | glob_pat: &Option,
[INFO] [stdout] ... |
[INFO] [stdout] 187 | | }
[INFO] [stdout] | |_^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ref_option
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 131 - glob_pat: &Option,
[INFO] [stdout] 131 + glob_pat: Option<&glob::Pattern>,
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/tools/search_files.rs:136:5
[INFO] [stdout] |
[INFO] [stdout] 136 | / let mut entries = match tokio::fs::read_dir(dir).await {
[INFO] [stdout] 137 | | Ok(e) => e,
[INFO] [stdout] 138 | | Err(_) => return,
[INFO] [stdout] 139 | | };
[INFO] [stdout] | |______^ help: consider writing: `let Ok(mut entries) = tokio::fs::read_dir(dir).await else { return };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout] = note: `#[warn(clippy::manual_let_else)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tools/shell.rs:66:23
[INFO] [stdout] |
[INFO] [stdout] 66 | .and_then(|v| v.as_bool())
[INFO] [stdout] | ^^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_bool`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (103/100)
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] 91 | | ) -> Result<()> {
[INFO] [stdout] | |___________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:135:29
[INFO] [stdout] |
[INFO] [stdout] 135 | / ... if !self.input.trim().is_empty() {
[INFO] [stdout] 136 | | ... let user_msg = self.input.clone();
[INFO] [stdout] 137 | | ... self.input.clear();
[INFO] [stdout] 138 | | ... self.cursor_pos = 0;
[INFO] [stdout] ... |
[INFO] [stdout] 176 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 134 ~ (KeyCode::Enter, _) if !agent_running
[INFO] [stdout] 135 ~ && !self.input.trim().is_empty() => {
[INFO] [stdout] 136 | let user_msg = self.input.clone();
[INFO] [stdout] ...
[INFO] [stdout] 175 | }
[INFO] [stdout] 176 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:183:29
[INFO] [stdout] |
[INFO] [stdout] 183 | / ... if self.cursor_pos > 0 {
[INFO] [stdout] 184 | | ... self.cursor_pos -= 1;
[INFO] [stdout] 185 | | ... self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 182 ~ (KeyCode::Backspace, _) if !agent_running
[INFO] [stdout] 183 ~ && self.cursor_pos > 0 => {
[INFO] [stdout] 184 | self.cursor_pos -= 1;
[INFO] [stdout] 185 | self.input.remove(self.cursor_pos);
[INFO] [stdout] 186 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `if` can be collapsed into the outer `match`
[INFO] [stdout] --> src/tui/app.rs:192:29
[INFO] [stdout] |
[INFO] [stdout] 192 | / ... if self.cursor_pos < self.input.len() {
[INFO] [stdout] 193 | | ... self.cursor_pos += 1;
[INFO] [stdout] 194 | | ... }
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match
[INFO] [stdout] help: collapse nested if block
[INFO] [stdout] |
[INFO] [stdout] 191 ~ (KeyCode::Right, _) if !agent_running
[INFO] [stdout] 192 ~ && self.cursor_pos < self.input.len() => {
[INFO] [stdout] 193 | self.cursor_pos += 1;
[INFO] [stdout] 194 ~ }
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:327:27
[INFO] [stdout] |
[INFO] [stdout] 327 | let total_lines = lines.len() as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] = note: `#[warn(clippy::cast_possible_truncation)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 327 - let total_lines = lines.len() as u16;
[INFO] [stdout] 327 + let total_lines = u16::try_from(lines.len());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this function has too many lines (107/100)
[INFO] [stdout] --> src/tui/app.rs:373:5
[INFO] [stdout] |
[INFO] [stdout] 373 | / fn handle_slash_command(
[INFO] [stdout] 374 | | &mut self,
[INFO] [stdout] 375 | | cmd: &str,
[INFO] [stdout] 376 | | agent_opt: &mut Option,
[INFO] [stdout] 377 | | ) -> Option {
[INFO] [stdout] | |_______________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#too_many_lines
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:424:29
[INFO] [stdout] |
[INFO] [stdout] 424 | let model = agent_opt
[INFO] [stdout] | _____________________________^
[INFO] [stdout] 425 | | .as_ref()
[INFO] [stdout] 426 | | .map(|a| a.model.as_str())
[INFO] [stdout] 427 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 426 - .map(|a| a.model.as_str())
[INFO] [stdout] 427 - .unwrap_or("unknown");
[INFO] [stdout] 426 + .map_or("unknown", |a| a.model.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or()` on an `Option` value
[INFO] [stdout] --> src/tui/app.rs:431:26
[INFO] [stdout] |
[INFO] [stdout] 431 | let id = agent_opt
[INFO] [stdout] | __________________________^
[INFO] [stdout] 432 | | .as_ref()
[INFO] [stdout] 433 | | .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 | | .unwrap_or("unknown");
[INFO] [stdout] | |_________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `map_or(, )` instead
[INFO] [stdout] |
[INFO] [stdout] 433 - .map(|a| a.session_id.as_str())
[INFO] [stdout] 434 - .unwrap_or("unknown");
[INFO] [stdout] 433 + .map_or("unknown", |a| a.session_id.as_str());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:446:33
[INFO] [stdout] |
[INFO] [stdout] 446 | / ... out.push_str(&format!(
[INFO] [stdout] 447 | | ... " {} ({} msgs) - {}\n",
[INFO] [stdout] 448 | | ... s.id, s.message_count, s.preview
[INFO] [stdout] 449 | | ... ));
[INFO] [stdout] | |________________________^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] = note: `#[warn(clippy::format_push_string)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 446 ~ let _ = write!(out, " {} ({} msgs) - {}\n",
[INFO] [stdout] 447 ~ s.id, s.message_count, s.preview);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: `format!(..)` appended to existing `String`
[INFO] [stdout] --> src/tui/app.rs:472:25
[INFO] [stdout] |
[INFO] [stdout] 472 | content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = note: you may need to import the `std::fmt::Write` trait
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[INFO] [stdout] help: consider using `write!` to avoid the extra allocation
[INFO] [stdout] |
[INFO] [stdout] 472 - content.push_str(&format!("{label}: {}\n\n", msg.content));
[INFO] [stdout] 472 + let _ = write!(content, "{label}: {}\n\n", msg.content);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `usize` to `u16` may truncate the value
[INFO] [stdout] --> src/tui/app.rs:503:37
[INFO] [stdout] |
[INFO] [stdout] 503 | let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ...
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_possible_truncation
[INFO] [stdout] help: ... or use `try_from` and handle the error accordingly
[INFO] [stdout] |
[INFO] [stdout] 503 - let cursor_x = area.x + 1 + self.cursor_pos as u16;
[INFO] [stdout] 503 + let cursor_x = area.x + 1 + u16::try_from(self.cursor_pos);
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/tui/mod.rs:276:49
[INFO] [stdout] |
[INFO] [stdout] 276 | tools.iter().find(|t| t.name() == name).map(|t| t.as_ref())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `std::convert::AsRef::as_ref`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unnecessary closure used to substitute value for `Option::None`
[INFO] [stdout] --> src/tui/mod.rs:341:55
[INFO] [stdout] |
[INFO] [stdout] 341 | Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_lazy_evaluations
[INFO] [stdout] help: use `unwrap_or` instead
[INFO] [stdout] |
[INFO] [stdout] 341 - Ok(r) => format!("Error: {}", r.error.unwrap_or_else(|| r.output)),
[INFO] [stdout] 341 + Ok(r) => format!("Error: {}", r.error.unwrap_or(r.output)),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this `map_or` can be simplified
[INFO] [stdout] --> src/tui/mod.rs:424:22
[INFO] [stdout] |
[INFO] [stdout] 424 | let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_map_or
[INFO] [stdout] help: use `is_some_and` instead
[INFO] [stdout] |
[INFO] [stdout] 424 - let has_system = history.first().map_or(false, |m| m.role == "system");
[INFO] [stdout] 424 + let has_system = history.first().is_some_and(|m| m.role == "system");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: boolean to int conversion using if
[INFO] [stdout] --> src/tui/mod.rs:433:17
[INFO] [stdout] |
[INFO] [stdout] 433 | let start = if has_system { 1 } else { 0 };
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with from: `usize::from(has_system)`
[INFO] [stdout] |
[INFO] [stdout] = note: `has_system as usize` or `has_system.into()` can also be valid options
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_to_int_with_if
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: constructing a `Duration` using a smaller unit when a larger unit would be more readable
[INFO] [stdout] --> src/gateway/mod.rs:813:63
[INFO] [stdout] |
[INFO] [stdout] 813 | idempotency_store: Arc::new(IdempotencyStore::new(Duration::from_secs(300))),
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#duration_suboptimal_units
[INFO] [stdout] help: try using from_mins
[INFO] [stdout] |
[INFO] [stdout] 813 - idempotency_store: Arc::new(IdempotencyStore::new(Duration::from_secs(300))),
[INFO] [stdout] 813 + idempotency_store: Arc::new(IdempotencyStore::new(Duration::from_mins(5))),
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: item in documentation is missing backticks
[INFO] [stdout] --> src/skillforge/mod.rs:1:5
[INFO] [stdout] |
[INFO] [stdout] 1 | //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] | ^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 1 - //! SkillForge — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] 1 + //! `SkillForge` — Skill auto-discovery, evaluation, and integration engine.
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:124:28
[INFO] [stdout] |
[INFO] [stdout] 124 | fn score_compatibility(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:134:22
[INFO] [stdout] |
[INFO] [stdout] 134 | fn score_quality(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: casting `u64` to `f64` may cause a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)
[INFO] [stdout] --> src/skillforge/evaluate.rs:136:20
[INFO] [stdout] |
[INFO] [stdout] 136 | let raw = ((c.stars as f64) + 1.0).log2() / 10.0;
[INFO] [stdout] | ^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#cast_precision_loss
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/evaluate.rs:141:23
[INFO] [stdout] |
[INFO] [stdout] 141 | fn score_security(&self, c: &ScoutResult) -> f64 {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:56:22
[INFO] [stdout] |
[INFO] [stdout] 56 | fn generate_toml(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or_else()` on an `Option` value
[INFO] [stdout] --> src/skillforge/integrate.rs:58:23
[INFO] [stdout] |
[INFO] [stdout] 58 | let updated = c
[INFO] [stdout] | _______________________^
[INFO] [stdout] 59 | | .updated_at
[INFO] [stdout] 60 | | .map(|d| d.format("%Y-%m-%d").to_string())
[INFO] [stdout] 61 | | .unwrap_or_else(|| "unknown".into());
[INFO] [stdout] | |________________________________________________^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: try
[INFO] [stdout] |
[INFO] [stdout] 58 ~ let updated = c
[INFO] [stdout] 59 ~ .updated_at.map_or_else(|| "unknown".into(), |d| d.format("%Y-%m-%d").to_string());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `self` argument
[INFO] [stdout] --> src/skillforge/integrate.rs:96:20
[INFO] [stdout] |
[INFO] [stdout] 96 | fn generate_md(&self, c: &ScoutResult) -> String {
[INFO] [stdout] | ^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: consider refactoring to an associated function
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: variables can be used directly in the `format!` string
[INFO] [stdout] --> src/skillforge/integrate.rs:165:9
[INFO] [stdout] |
[INFO] [stdout] 165 | bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
[INFO] [stdout] help: change this to
[INFO] [stdout] |
[INFO] [stdout] 165 - bail!("Skill name '{}' is unsafe as a path component", name);
[INFO] [stdout] 165 + bail!("Skill name '{name}' is unsafe as a path component");
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this argument is passed by value, but not consumed in the function body
[INFO] [stdout] --> src/skillforge/scout.rs:76:23
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option) -> Self {
[INFO] [stdout] | ^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[INFO] [stdout] help: consider taking a reference instead
[INFO] [stdout] |
[INFO] [stdout] 76 | pub fn new(token: Option<&String>) -> Self {
[INFO] [stdout] | +
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: this could be rewritten as `let...else`
[INFO] [stdout] --> src/skillforge/scout.rs:108:9
[INFO] [stdout] |
[INFO] [stdout] 108 | / let items = match body.get("items").and_then(|v| v.as_array()) {
[INFO] [stdout] 109 | | Some(arr) => arr,
[INFO] [stdout] 110 | | None => return vec![],
[INFO] [stdout] 111 | | };
[INFO] [stdout] | |__________^ help: consider writing: `let Some(items) = body.get("items").and_then(|v| v.as_array()) else { return vec![] };`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: redundant closure
[INFO] [stdout] --> src/skillforge/scout.rs:125:31
[INFO] [stdout] |
[INFO] [stdout] 125 | .and_then(|v| v.as_u64())
[INFO] [stdout] | ^^^^^^^^^^^^^^ help: replace the closure with the method itself: `serde_json::Value::as_u64`
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure_for_method_calls
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: called `map().unwrap_or(false)` on an `Option` value
[INFO] [stdout] --> src/skillforge/scout.rs:141:35
[INFO] [stdout] |
[INFO] [stdout] 141 | let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[INFO] [stdout] |
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_unwrap_or
[INFO] [stdout] help: use `is_some_and()` instead
[INFO] [stdout] |
[INFO] [stdout] 141 - let has_license = item.get("license").map(|v| !v.is_null()).unwrap_or(false);
[INFO] [stdout] 141 + let has_license = item.get("license").is_some_and(|v| !v.is_null());
[INFO] [stdout] |
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stdout] warning: unused `async` for function with no await statements
[INFO] [stdout] --> src/tui/app.rs:87:5
[INFO] [stdout] |
[INFO] [stdout] 87 | / async fn event_loop(
[INFO] [stdout] 88 | | &mut self,
[INFO] [stdout] 89 | | terminal: &mut Terminal>,
[INFO] [stdout] 90 | | agent: AgentState,
[INFO] [stdout] ... |
[INFO] [stdout] 210 | | Ok(())
[INFO] [stdout] 211 | | }
[INFO] [stdout] | |_____^
[INFO] [stdout] |
[INFO] [stdout] = help: consider removing the `async` from this function
[INFO] [stdout] note: `await` used in an async block, which does not require the enclosing function to be `async`
[INFO] [stdout] --> src/tui/app.rs:172:75
[INFO] [stdout] |
[INFO] [stdout] 172 | ... ag.handle_message(&user_msg, &tx).await;
[INFO] [stdout] | ^^^^^
[INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_async
[INFO] [stdout] = note: `#[warn(clippy::unused_async)]` implied by `#[warn(clippy::pedantic)]`
[INFO] [stdout]
[INFO] [stdout]
[INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 1m 53s
[INFO] running `Command { std: "docker" "inspect" "10b0c836063c701c47d80c9cdc1634bcde16ee1f7e9c7c147b050c6bceace6ab", kill_on_drop: false }`
[INFO] running `Command { std: "docker" "rm" "-f" "10b0c836063c701c47d80c9cdc1634bcde16ee1f7e9c7c147b050c6bceace6ab", kill_on_drop: false }`
[INFO] [stdout] 10b0c836063c701c47d80c9cdc1634bcde16ee1f7e9c7c147b050c6bceace6ab