[INFO] fetching crate rust-agent 0.0.5... [INFO] linting rust-agent-0.0.5 against nightly for clippy-nonminimal_bool-denied [INFO] extracting crate rust-agent 0.0.5 into /workspace/builds/worker-6-tc1/source [INFO] started tweaking crates.io crate rust-agent 0.0.5 [INFO] removed 0 missing examples [INFO] finished tweaking crates.io crate rust-agent 0.0.5 [INFO] tweaked toml for crates.io crate rust-agent 0.0.5 written to /workspace/builds/worker-6-tc1/source/Cargo.toml [INFO] validating manifest of crates.io crate rust-agent 0.0.5 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 crates.io crate rust-agent 0.0.5 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 rust-ini v0.21.3 [INFO] [stderr] Downloaded proc-macro2 v1.0.102 [INFO] [stderr] Downloaded config v0.15.18 [INFO] [stderr] Downloaded yaml-rust2 v0.10.4 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-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] a4ffdc489a5f678820e9fdac7a8afe0ceb16e0086577f18456c6f9e7398b71ba [INFO] running `Command { std: "docker" "start" "-a" "a4ffdc489a5f678820e9fdac7a8afe0ceb16e0086577f18456c6f9e7398b71ba", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "a4ffdc489a5f678820e9fdac7a8afe0ceb16e0086577f18456c6f9e7398b71ba", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "a4ffdc489a5f678820e9fdac7a8afe0ceb16e0086577f18456c6f9e7398b71ba", kill_on_drop: false }` [INFO] [stdout] a4ffdc489a5f678820e9fdac7a8afe0ceb16e0086577f18456c6f9e7398b71ba [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-6-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] 35bae3d7c0be0374e5ccaba56a91b8ded2c9656cc5a4e9abc8948379f711dc1b [INFO] running `Command { std: "docker" "start" "-a" "35bae3d7c0be0374e5ccaba56a91b8ded2c9656cc5a4e9abc8948379f711dc1b", kill_on_drop: false }` [INFO] [stderr] Compiling proc-macro2 v1.0.102 [INFO] [stderr] Compiling unicode-ident v1.0.20 [INFO] [stderr] Compiling quote v1.0.41 [INFO] [stderr] Compiling serde_core v1.0.228 [INFO] [stderr] Checking stable_deref_trait v1.2.1 [INFO] [stderr] Compiling cc v1.2.41 [INFO] [stderr] Compiling libc v0.2.177 [INFO] [stderr] Checking parking_lot_core v0.9.12 [INFO] [stderr] Checking signal-hook-registry v1.4.6 [INFO] [stderr] Checking tracing v0.1.41 [INFO] [stderr] Compiling once_cell v1.21.3 [INFO] [stderr] Compiling openssl v0.10.74 [INFO] [stderr] Compiling pest v2.8.3 [INFO] [stderr] Checking http v0.2.12 [INFO] [stderr] Compiling typeid v1.0.3 [INFO] [stderr] Checking hashbrown v0.16.0 [INFO] [stderr] Compiling serde_json v1.0.145 [INFO] [stderr] Checking aho-corasick v1.1.3 [INFO] [stderr] Checking parking_lot v0.12.5 [INFO] [stderr] Checking base64 v0.21.7 [INFO] [stderr] Compiling erased-serde v0.4.8 [INFO] [stderr] Checking hashbrown v0.15.5 [INFO] [stderr] Checking socket2 v0.5.10 [INFO] [stderr] Compiling rustix v1.1.2 [INFO] [stderr] Checking sync_wrapper v1.0.2 [INFO] [stderr] Checking hashbrown v0.14.5 [INFO] [stderr] Checking toml_parser v1.0.4 [INFO] [stderr] Checking getrandom v0.3.4 [INFO] [stderr] Checking arraydeque v0.5.1 [INFO] [stderr] Checking anstream v0.6.21 [INFO] [stderr] Checking convert_case v0.6.0 [INFO] [stderr] Checking rustls-pemfile v1.0.4 [INFO] [stderr] Checking jiff v0.2.15 [INFO] [stderr] Checking matchit v0.7.3 [INFO] [stderr] Checking sync_wrapper v0.1.2 [INFO] [stderr] Compiling syn v2.0.108 [INFO] [stderr] Checking indexmap v2.12.0 [INFO] [stderr] Checking hashlink v0.10.0 [INFO] [stderr] Checking regex-automata v0.4.13 [INFO] [stderr] Checking yaml-rust2 v0.10.4 [INFO] [stderr] Checking http-body v0.4.6 [INFO] [stderr] Compiling getrandom v0.2.16 [INFO] [stderr] Compiling const-random-macro v0.1.16 [INFO] [stderr] Compiling openssl-sys v0.9.110 [INFO] [stderr] Compiling pest_meta v2.8.3 [INFO] [stderr] Compiling native-tls v0.2.14 [INFO] [stderr] Checking const-random v0.1.18 [INFO] [stderr] Checking dlv-list v0.5.2 [INFO] [stderr] Checking ordered-multimap v0.7.3 [INFO] [stderr] Checking bitflags v2.10.0 [INFO] [stderr] Checking toml_datetime v0.7.3 [INFO] [stderr] Checking serde_spanned v1.0.3 [INFO] [stderr] Checking serde_path_to_error v0.1.20 [INFO] [stderr] Checking rust-ini v0.21.3 [INFO] [stderr] Checking tower-http v0.5.2 [INFO] [stderr] Checking toml v0.9.8 [INFO] [stderr] Checking serde-untagged v0.1.9 [INFO] [stderr] Checking regex v1.12.2 [INFO] [stderr] Checking env_filter v0.1.4 [INFO] [stderr] Checking env_logger v0.11.8 [INFO] [stderr] Checking tempfile v3.23.0 [INFO] [stderr] Compiling synstructure v0.13.2 [INFO] [stderr] Compiling pest_generator v2.8.3 [INFO] [stderr] Compiling zerofrom-derive v0.1.6 [INFO] [stderr] Compiling yoke-derive v0.8.0 [INFO] [stderr] Compiling tokio-macros v2.6.0 [INFO] [stderr] Compiling zerovec-derive v0.11.1 [INFO] [stderr] Compiling displaydoc v0.2.5 [INFO] [stderr] Compiling futures-macro v0.3.31 [INFO] [stderr] Compiling serde_derive v1.0.228 [INFO] [stderr] Compiling openssl-macros v0.1.1 [INFO] [stderr] Compiling async-trait v0.1.89 [INFO] [stderr] Compiling axum-macros v0.4.2 [INFO] [stderr] Compiling pest_derive v2.8.3 [INFO] [stderr] Checking futures-util v0.3.31 [INFO] [stderr] Checking tokio v1.48.0 [INFO] [stderr] Checking zerofrom v0.1.6 [INFO] [stderr] Checking yoke v0.8.0 [INFO] [stderr] Checking zerovec v0.11.4 [INFO] [stderr] Checking zerotrie v0.2.2 [INFO] [stderr] Checking tinystr v0.8.1 [INFO] [stderr] Checking potential_utf v0.1.3 [INFO] [stderr] Checking icu_locale_core v2.0.0 [INFO] [stderr] Checking icu_collections v2.0.0 [INFO] [stderr] Checking icu_provider v2.0.0 [INFO] [stderr] Checking serde v1.0.228 [INFO] [stderr] Checking icu_normalizer v2.0.0 [INFO] [stderr] Checking icu_properties v2.0.1 [INFO] [stderr] Checking serde_urlencoded v0.7.1 [INFO] [stderr] Checking json5 v0.4.1 [INFO] [stderr] Checking ron v0.8.1 [INFO] [stderr] Checking uuid v1.18.1 [INFO] [stderr] Checking axum-core v0.4.5 [INFO] [stderr] Checking futures-executor v0.3.31 [INFO] [stderr] Checking futures v0.3.31 [INFO] [stderr] Checking idna_adapter v1.2.1 [INFO] [stderr] Checking idna v1.1.0 [INFO] [stderr] Checking config v0.15.18 [INFO] [stderr] Checking url v2.5.7 [INFO] [stderr] Checking tokio-util v0.7.16 [INFO] [stderr] Checking hyper v1.7.0 [INFO] [stderr] Checking tokio-native-tls v0.3.1 [INFO] [stderr] Checking tower v0.5.2 [INFO] [stderr] Checking h2 v0.3.27 [INFO] [stderr] Checking tokio-stream v0.1.17 [INFO] [stderr] Checking hyper-util v0.1.17 [INFO] [stderr] Checking axum v0.7.9 [INFO] [stderr] Checking hyper v0.14.32 [INFO] [stderr] Checking hyper-tls v0.5.0 [INFO] [stderr] Checking reqwest v0.11.27 [INFO] [stderr] Checking rust-agent v0.0.5 (/opt/rustwide/workdir) [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> src/models/openai.rs:7:1 [INFO] [stdout] | [INFO] [stdout] 7 | use serde_json; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] = note: `#[warn(clippy::single_component_path_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Path` [INFO] [stdout] --> src/memory/message_history.rs:2:17 [INFO] [stdout] | [INFO] [stdout] 2 | use std::path::{Path, PathBuf}; [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `ChatMessageContent`, `ModelChatMessage`, and `OpenAIChatModel` [INFO] [stdout] --> src/memory/summary.rs:20:24 [INFO] [stdout] | [INFO] [stdout] 20 | use crate::{ChatModel, OpenAIChatModel, ModelChatMessage, ChatMessageContent}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize` [INFO] [stdout] --> src/memory/utils.rs:4:13 [INFO] [stdout] | [INFO] [stdout] 4 | use serde::{Serialize, Deserialize}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `error` and `warn` [INFO] [stdout] --> src/memory/composite_memory.rs:11:17 [INFO] [stdout] | [INFO] [stdout] 11 | use log::{info, warn, error}; [INFO] [stdout] | ^^^^ ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> src/models/openai.rs:7:1 [INFO] [stdout] | [INFO] [stdout] 7 | use serde_json; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] = note: `#[warn(clippy::single_component_path_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Path` [INFO] [stdout] --> src/memory/message_history.rs:2:17 [INFO] [stdout] | [INFO] [stdout] 2 | use std::path::{Path, PathBuf}; [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `ChatMessageContent`, `ModelChatMessage`, and `OpenAIChatModel` [INFO] [stdout] --> src/memory/summary.rs:20:24 [INFO] [stdout] | [INFO] [stdout] 20 | use crate::{ChatModel, OpenAIChatModel, ModelChatMessage, ChatMessageContent}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize` [INFO] [stdout] --> src/memory/utils.rs:4:13 [INFO] [stdout] | [INFO] [stdout] 4 | use serde::{Serialize, Deserialize}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `error` and `warn` [INFO] [stdout] --> src/memory/composite_memory.rs:11:17 [INFO] [stdout] | [INFO] [stdout] 11 | use log::{info, warn, error}; [INFO] [stdout] | ^^^^ ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type `models::openai::OpenAIApiType` is more private than the item `models::openai::OpenAIChatModel::with_api_type` [INFO] [stdout] --> src/models/openai.rs:154:5 [INFO] [stdout] | [INFO] [stdout] 154 | pub fn with_api_type(mut self, api_type: OpenAIApiType) -> Self { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ method `models::openai::OpenAIChatModel::with_api_type` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but type `models::openai::OpenAIApiType` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/models/openai.rs:80:1 [INFO] [stdout] | [INFO] [stdout] 80 | enum OpenAIApiType { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `#[warn(private_interfaces)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `audio_tokens`, `cache_read`, and `reasoning_tokens` are never read [INFO] [stdout] --> src/models/openai.rs:22:5 [INFO] [stdout] | [INFO] [stdout] 21 | struct InputTokenDetails { [INFO] [stdout] | ----------------- fields in this struct [INFO] [stdout] 22 | audio_tokens: Option, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 23 | cache_read: Option, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 24 | reasoning_tokens: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `cache_write` and `reasoning_tokens` are never read [INFO] [stdout] --> src/models/openai.rs:30:5 [INFO] [stdout] | [INFO] [stdout] 29 | struct OutputTokenDetails { [INFO] [stdout] | ------------------ fields in this struct [INFO] [stdout] 30 | cache_write: Option, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 31 | reasoning_tokens: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `input_tokens_details` and `output_tokens_details` are never read [INFO] [stdout] --> src/models/openai.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 37 | struct OpenAIUsage { [INFO] [stdout] | ----------- fields in this struct [INFO] [stdout] ... [INFO] [stdout] 42 | input_tokens_details: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 43 | output_tokens_details: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `OpenAIResponsesUsage` is never constructed [INFO] [stdout] --> src/models/openai.rs:48:8 [INFO] [stdout] | [INFO] [stdout] 48 | struct OpenAIResponsesUsage { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `id`, `object`, and `created` are never read [INFO] [stdout] --> src/models/openai.rs:60:5 [INFO] [stdout] | [INFO] [stdout] 59 | struct OpenAIResponse { [INFO] [stdout] | -------------- fields in this struct [INFO] [stdout] 60 | id: Option, [INFO] [stdout] | ^^ [INFO] [stdout] 61 | object: Option, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 62 | created: Option, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `index` and `finish_reason` are never read [INFO] [stdout] --> src/models/openai.rs:73:5 [INFO] [stdout] | [INFO] [stdout] 72 | struct OpenAIChoice { [INFO] [stdout] | ------------ fields in this struct [INFO] [stdout] 73 | index: u32, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 74 | message: OpenAIMessage, [INFO] [stdout] 75 | finish_reason: String, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `Responses` is never constructed [INFO] [stdout] --> src/models/openai.rs:82:5 [INFO] [stdout] | [INFO] [stdout] 80 | enum OpenAIApiType { [INFO] [stdout] | ------------- variant in this enum [INFO] [stdout] 81 | ChatCompletions, [INFO] [stdout] 82 | Responses, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `OpenAIApiType` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/core/runnable.rs:24:40 [INFO] [stdout] | [INFO] [stdout] 24 | fn batch(&self, inputs: Vec) -> Pin>> + Send>> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] = note: `#[warn(clippy::type_complexity)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/core/runnable.rs:43:10 [INFO] [stdout] | [INFO] [stdout] 43 | ) -> Pin>> + Send>> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/core/runnable.rs:68:10 [INFO] [stdout] | [INFO] [stdout] 68 | ) -> Pin> + Send>> + Send>> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:88:41 [INFO] [stdout] | [INFO] [stdout] 88 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] = note: `#[warn(clippy::implied_bounds_in_impls)]` on by default [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 88 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 88 + next: impl Runnable + Sync + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:88:48 [INFO] [stdout] | [INFO] [stdout] 88 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 88 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 88 + next: impl Runnable + Send + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:89:36 [INFO] [stdout] | [INFO] [stdout] 89 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 89 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 89 + ) -> impl Runnable + Sync [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:89:43 [INFO] [stdout] | [INFO] [stdout] 89 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 89 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 89 + ) -> impl Runnable + Send [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:98:41 [INFO] [stdout] | [INFO] [stdout] 98 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 98 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 98 + next: impl Runnable + Sync + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:98:48 [INFO] [stdout] | [INFO] [stdout] 98 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 98 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 98 + next: impl Runnable + Send + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:99:36 [INFO] [stdout] | [INFO] [stdout] 99 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 99 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 99 + ) -> impl Runnable + Sync [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:99:43 [INFO] [stdout] | [INFO] [stdout] 99 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 99 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 99 + ) -> impl Runnable + Send [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:110:35 [INFO] [stdout] | [INFO] [stdout] 110 | first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 110 - first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] 110 + first: impl Runnable + Sync + 'static, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:110:42 [INFO] [stdout] | [INFO] [stdout] 110 | first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 110 - first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] 110 + first: impl Runnable + Send + 'static, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:111:37 [INFO] [stdout] | [INFO] [stdout] 111 | second: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 111 - second: impl Runnable + Send + Sync + 'static [INFO] [stdout] 111 + second: impl Runnable + Sync + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:111:44 [INFO] [stdout] | [INFO] [stdout] 111 | second: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 111 - second: impl Runnable + Send + Sync + 'static [INFO] [stdout] 111 + second: impl Runnable + Send + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:161:48 [INFO] [stdout] | [INFO] [stdout] 161 | pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 161 - pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] 161 + pub fn new(runnable: impl Runnable + Sync + 'static) -> Self { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:161:55 [INFO] [stdout] | [INFO] [stdout] 161 | pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 161 - pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] 161 + pub fn new(runnable: impl Runnable + Send + 'static) -> Self { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: parameter is only used in recursion [INFO] [stdout] --> src/core/runnable.rs:185:22 [INFO] [stdout] | [INFO] [stdout] 185 | fn invoke(&self, input: I) -> Pin> + Send>> { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] | [INFO] [stdout] note: parameter used here [INFO] [stdout] --> src/core/runnable.rs:188:31 [INFO] [stdout] | [INFO] [stdout] 188 | self_clone.invoke(input).await [INFO] [stdout] | ^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#only_used_in_recursion [INFO] [stdout] = note: `#[warn(clippy::only_used_in_recursion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant redefinition of a binding `messages` [INFO] [stdout] --> src/models/openai.rs:236:9 [INFO] [stdout] | [INFO] [stdout] 236 | let messages = messages; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: `messages` is initially defined here [INFO] [stdout] --> src/models/openai.rs:235:22 [INFO] [stdout] | [INFO] [stdout] 235 | fn invoke(&self, messages: Vec) -> std::pin::Pin src/models/openai.rs:367:25 [INFO] [stdout] | [INFO] [stdout] 367 | let usage = match &response.usage { [INFO] [stdout] | _________________________^ [INFO] [stdout] 368 | | Some(openai_usage) => { [INFO] [stdout] 369 | | Some(TokenUsage { [INFO] [stdout] 370 | | prompt_tokens: openai_usage.prompt_tokens, [INFO] [stdout] ... | [INFO] [stdout] 375 | | None => None, [INFO] [stdout] 376 | | }; [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_map [INFO] [stdout] = note: `#[warn(clippy::manual_map)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 367 ~ let usage = response.usage.as_ref().map(|openai_usage| TokenUsage { [INFO] [stdout] 368 + prompt_tokens: openai_usage.prompt_tokens, [INFO] [stdout] 369 + completion_tokens: openai_usage.completion_tokens, [INFO] [stdout] 370 + total_tokens: openai_usage.total_tokens, [INFO] [stdout] 371 ~ }); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `ExampleToolkit` [INFO] [stdout] --> src/tools/tool.rs:70:5 [INFO] [stdout] | [INFO] [stdout] 70 | / pub fn new() -> Self { [INFO] [stdout] 71 | | let tools: Vec> = Vec::new(); [INFO] [stdout] 72 | | Self { [INFO] [stdout] 73 | | tools, [INFO] [stdout] 74 | | } [INFO] [stdout] 75 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 69 + impl Default for ExampleToolkit { [INFO] [stdout] 70 + fn default() -> Self { [INFO] [stdout] 71 + Self::new() [INFO] [stdout] 72 + } [INFO] [stdout] 73 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/memory/base.rs:20:83 [INFO] [stdout] | [INFO] [stdout] 20 | ...hMap) -> Pin, Error>> + Send + 'a>>; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type `models::openai::OpenAIApiType` is more private than the item `models::openai::OpenAIChatModel::with_api_type` [INFO] [stdout] --> src/models/openai.rs:154:5 [INFO] [stdout] | [INFO] [stdout] 154 | pub fn with_api_type(mut self, api_type: OpenAIApiType) -> Self { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ method `models::openai::OpenAIChatModel::with_api_type` is reachable at visibility `pub` [INFO] [stdout] | [INFO] [stdout] note: but type `models::openai::OpenAIApiType` is only usable at visibility `pub(self)` [INFO] [stdout] --> src/models/openai.rs:80:1 [INFO] [stdout] | [INFO] [stdout] 80 | enum OpenAIApiType { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: `#[warn(private_interfaces)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/memory/message_history.rs:116:12 [INFO] [stdout] | [INFO] [stdout] 116 | if !tokio::fs::metadata(&self.file_path).await.is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `tokio::fs::metadata(&self.file_path).await.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `audio_tokens`, `cache_read`, and `reasoning_tokens` are never read [INFO] [stdout] --> src/models/openai.rs:22:5 [INFO] [stdout] | [INFO] [stdout] 21 | struct InputTokenDetails { [INFO] [stdout] | ----------------- fields in this struct [INFO] [stdout] 22 | audio_tokens: Option, [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] 23 | cache_read: Option, [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] 24 | reasoning_tokens: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `cache_write` and `reasoning_tokens` are never read [INFO] [stdout] --> src/models/openai.rs:30:5 [INFO] [stdout] | [INFO] [stdout] 29 | struct OutputTokenDetails { [INFO] [stdout] | ------------------ fields in this struct [INFO] [stdout] 30 | cache_write: Option, [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] 31 | reasoning_tokens: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `input_tokens_details` and `output_tokens_details` are never read [INFO] [stdout] --> src/models/openai.rs:42:5 [INFO] [stdout] | [INFO] [stdout] 37 | struct OpenAIUsage { [INFO] [stdout] | ----------- fields in this struct [INFO] [stdout] ... [INFO] [stdout] 42 | input_tokens_details: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] 43 | output_tokens_details: Option, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: struct `OpenAIResponsesUsage` is never constructed [INFO] [stdout] --> src/models/openai.rs:48:8 [INFO] [stdout] | [INFO] [stdout] 48 | struct OpenAIResponsesUsage { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `id`, `object`, and `created` are never read [INFO] [stdout] --> src/models/openai.rs:60:5 [INFO] [stdout] | [INFO] [stdout] 59 | struct OpenAIResponse { [INFO] [stdout] | -------------- fields in this struct [INFO] [stdout] 60 | id: Option, [INFO] [stdout] | ^^ [INFO] [stdout] 61 | object: Option, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] 62 | created: Option, [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: fields `index` and `finish_reason` are never read [INFO] [stdout] --> src/models/openai.rs:73:5 [INFO] [stdout] | [INFO] [stdout] 72 | struct OpenAIChoice { [INFO] [stdout] | ------------ fields in this struct [INFO] [stdout] 73 | index: u32, [INFO] [stdout] | ^^^^^ [INFO] [stdout] 74 | message: OpenAIMessage, [INFO] [stdout] 75 | finish_reason: String, [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variant `Responses` is never constructed [INFO] [stdout] --> src/models/openai.rs:82:5 [INFO] [stdout] | [INFO] [stdout] 80 | enum OpenAIApiType { [INFO] [stdout] | ------------- variant in this enum [INFO] [stdout] 81 | ChatCompletions, [INFO] [stdout] 82 | Responses, [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `OpenAIApiType` has derived impls for the traits `Clone` and `Debug`, but these are intentionally ignored during dead code analysis [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/core/runnable.rs:24:40 [INFO] [stdout] | [INFO] [stdout] 24 | fn batch(&self, inputs: Vec) -> Pin>> + Send>> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] = note: `#[warn(clippy::type_complexity)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/core/runnable.rs:43:10 [INFO] [stdout] | [INFO] [stdout] 43 | ) -> Pin>> + Send>> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/core/runnable.rs:68:10 [INFO] [stdout] | [INFO] [stdout] 68 | ) -> Pin> + Send>> + Send>> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:88:41 [INFO] [stdout] | [INFO] [stdout] 88 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] = note: `#[warn(clippy::implied_bounds_in_impls)]` on by default [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 88 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 88 + next: impl Runnable + Sync + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:88:48 [INFO] [stdout] | [INFO] [stdout] 88 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 88 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 88 + next: impl Runnable + Send + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:89:36 [INFO] [stdout] | [INFO] [stdout] 89 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 89 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 89 + ) -> impl Runnable + Sync [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:89:43 [INFO] [stdout] | [INFO] [stdout] 89 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 89 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 89 + ) -> impl Runnable + Send [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:98:41 [INFO] [stdout] | [INFO] [stdout] 98 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 98 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 98 + next: impl Runnable + Sync + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:98:48 [INFO] [stdout] | [INFO] [stdout] 98 | next: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 98 - next: impl Runnable + Send + Sync + 'static [INFO] [stdout] 98 + next: impl Runnable + Send + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:99:36 [INFO] [stdout] | [INFO] [stdout] 99 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 99 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 99 + ) -> impl Runnable + Sync [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:99:43 [INFO] [stdout] | [INFO] [stdout] 99 | ) -> impl Runnable + Send + Sync [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 99 - ) -> impl Runnable + Send + Sync [INFO] [stdout] 99 + ) -> impl Runnable + Send [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:110:35 [INFO] [stdout] | [INFO] [stdout] 110 | first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 110 - first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] 110 + first: impl Runnable + Sync + 'static, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:110:42 [INFO] [stdout] | [INFO] [stdout] 110 | first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 110 - first: impl Runnable + Send + Sync + 'static, [INFO] [stdout] 110 + first: impl Runnable + Send + 'static, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:111:37 [INFO] [stdout] | [INFO] [stdout] 111 | second: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 111 - second: impl Runnable + Send + Sync + 'static [INFO] [stdout] 111 + second: impl Runnable + Sync + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:111:44 [INFO] [stdout] | [INFO] [stdout] 111 | second: impl Runnable + Send + Sync + 'static [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 111 - second: impl Runnable + Send + Sync + 'static [INFO] [stdout] 111 + second: impl Runnable + Send + 'static [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:161:48 [INFO] [stdout] | [INFO] [stdout] 161 | pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 161 - pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] 161 + pub fn new(runnable: impl Runnable + Sync + 'static) -> Self { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this bound is already specified as the supertrait of `Runnable` [INFO] [stdout] --> src/core/runnable.rs:161:55 [INFO] [stdout] | [INFO] [stdout] 161 | pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implied_bounds_in_impls [INFO] [stdout] help: try removing this bound [INFO] [stdout] | [INFO] [stdout] 161 - pub fn new(runnable: impl Runnable + Send + Sync + 'static) -> Self { [INFO] [stdout] 161 + pub fn new(runnable: impl Runnable + Send + 'static) -> Self { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: parameter is only used in recursion [INFO] [stdout] --> src/core/runnable.rs:185:22 [INFO] [stdout] | [INFO] [stdout] 185 | fn invoke(&self, input: I) -> Pin> + Send>> { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] | [INFO] [stdout] note: parameter used here [INFO] [stdout] --> src/core/runnable.rs:188:31 [INFO] [stdout] | [INFO] [stdout] 188 | self_clone.invoke(input).await [INFO] [stdout] | ^^^^^ [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#only_used_in_recursion [INFO] [stdout] = note: `#[warn(clippy::only_used_in_recursion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/memory/summary.rs:172:12 [INFO] [stdout] | [INFO] [stdout] 172 | if !tokio::fs::metadata(&file_path).await.is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `tokio::fs::metadata(&file_path).await.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: matching on `Some` with `ok()` is redundant [INFO] [stdout] --> src/memory/summary.rs:422:13 [INFO] [stdout] | [INFO] [stdout] 422 | if let Some(user_system_prompt) = std::env::var("USER_SYSTEM_PROMPT").ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_result_ok [INFO] [stdout] = note: `#[warn(clippy::match_result_ok)]` on by default [INFO] [stdout] help: consider matching on `Ok(user_system_prompt)` and removing the call to `ok` instead [INFO] [stdout] | [INFO] [stdout] 422 - if let Some(user_system_prompt) = std::env::var("USER_SYSTEM_PROMPT").ok() { [INFO] [stdout] 422 + if let Ok(user_system_prompt) = std::env::var("USER_SYSTEM_PROMPT") { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual arithmetic check found [INFO] [stdout] --> src/memory/summary.rs:442:25 [INFO] [stdout] | [INFO] [stdout] 442 | let start = if len > recent_messages_count { [INFO] [stdout] | _________________________^ [INFO] [stdout] 443 | | len - recent_messages_count [INFO] [stdout] 444 | | } else { [INFO] [stdout] 445 | | 0 [INFO] [stdout] 446 | | }; [INFO] [stdout] | |_____________^ help: replace it with: `len.saturating_sub(recent_messages_count)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_saturating_sub [INFO] [stdout] = note: `#[warn(clippy::implicit_saturating_sub)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant redefinition of a binding `messages` [INFO] [stdout] --> src/models/openai.rs:236:9 [INFO] [stdout] | [INFO] [stdout] 236 | let messages = messages; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] help: `messages` is initially defined here [INFO] [stdout] --> src/models/openai.rs:235:22 [INFO] [stdout] | [INFO] [stdout] 235 | fn invoke(&self, messages: Vec) -> std::pin::Pin src/models/openai.rs:367:25 [INFO] [stdout] | [INFO] [stdout] 367 | let usage = match &response.usage { [INFO] [stdout] | _________________________^ [INFO] [stdout] 368 | | Some(openai_usage) => { [INFO] [stdout] 369 | | Some(TokenUsage { [INFO] [stdout] 370 | | prompt_tokens: openai_usage.prompt_tokens, [INFO] [stdout] ... | [INFO] [stdout] 375 | | None => None, [INFO] [stdout] 376 | | }; [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_map [INFO] [stdout] = note: `#[warn(clippy::manual_map)]` on by default [INFO] [stdout] help: try [INFO] [stdout] | [INFO] [stdout] 367 ~ let usage = response.usage.as_ref().map(|openai_usage| TokenUsage { [INFO] [stdout] 368 + prompt_tokens: openai_usage.prompt_tokens, [INFO] [stdout] 369 + completion_tokens: openai_usage.completion_tokens, [INFO] [stdout] 370 + total_tokens: openai_usage.total_tokens, [INFO] [stdout] 371 ~ }); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `ExampleToolkit` [INFO] [stdout] --> src/tools/tool.rs:70:5 [INFO] [stdout] | [INFO] [stdout] 70 | / pub fn new() -> Self { [INFO] [stdout] 71 | | let tools: Vec> = Vec::new(); [INFO] [stdout] 72 | | Self { [INFO] [stdout] 73 | | tools, [INFO] [stdout] 74 | | } [INFO] [stdout] 75 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 69 + impl Default for ExampleToolkit { [INFO] [stdout] 70 + fn default() -> Self { [INFO] [stdout] 71 + Self::new() [INFO] [stdout] 72 + } [INFO] [stdout] 73 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/memory/base.rs:20:83 [INFO] [stdout] | [INFO] [stdout] 20 | ...hMap) -> Pin, Error>> + Send + 'a>>; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/memory/composite_memory.rs:96:29 [INFO] [stdout] | [INFO] [stdout] 96 | .unwrap_or_else(|| generate_session_id()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `generate_session_id` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default() [INFO] [stdout] --> src/memory/composite_memory.rs:126:9 [INFO] [stdout] | [INFO] [stdout] 126 | config.session_id = Some(session_id); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: consider initializing the variable with `memory::composite_memory::CompositeMemoryConfig { session_id: Some(session_id), ..Default::default() }` and removing relevant reassignments [INFO] [stdout] --> src/memory/composite_memory.rs:125:9 [INFO] [stdout] | [INFO] [stdout] 125 | let mut config = CompositeMemoryConfig::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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/memory/message_history.rs:116:12 [INFO] [stdout] | [INFO] [stdout] 116 | if !tokio::fs::metadata(&self.file_path).await.is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `tokio::fs::metadata(&self.file_path).await.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `SimpleAgent` [INFO] [stdout] --> src/agents/agent.rs:67:5 [INFO] [stdout] | [INFO] [stdout] 67 | / pub fn new() -> Self { [INFO] [stdout] 68 | | Self { [INFO] [stdout] 69 | | tools: Vec::new(), [INFO] [stdout] 70 | | } [INFO] [stdout] 71 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 66 + impl Default for SimpleAgent { [INFO] [stdout] 67 + fn default() -> Self { [INFO] [stdout] 68 + Self::new() [INFO] [stdout] 69 + } [INFO] [stdout] 70 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to be trying to use `&Box`. Consider using just `&T` [INFO] [stdout] --> src/agents/mcp_agent.rs:68:40 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn get_memory(&self) -> Option<&Box> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: try: `&dyn BaseMemory` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrowed_box [INFO] [stdout] = note: `#[warn(clippy::borrowed_box)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/agents/mcp_agent.rs:459:33 [INFO] [stdout] | [INFO] [stdout] 459 | ... return Ok(AgentOutput::Action(action)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 459 - return Ok(AgentOutput::Action(action)); [INFO] [stdout] 459 + Ok(AgentOutput::Action(action)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/agents/mcp_agent.rs:466:33 [INFO] [stdout] | [INFO] [stdout] 466 | ... return Ok(AgentOutput::Finish(AgentFinish { return_values })); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 466 - return Ok(AgentOutput::Finish(AgentFinish { return_values })); [INFO] [stdout] 466 + Ok(AgentOutput::Finish(AgentFinish { return_values })) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if let` can be collapsed into the outer `if let` [INFO] [stdout] --> src/agents/mcp_agent.rs:304:29 [INFO] [stdout] | [INFO] [stdout] 304 | / ... if let serde_json::Value::Array(messages_array) = chat_history { [INFO] [stdout] 305 | | ... for message in messages_array { [INFO] [stdout] 306 | | ... if let serde_json::Value::Object(msg_obj) = message { [INFO] [stdout] 307 | | ... let role = msg_obj.get("role").and_then(|v| v.as_str()).unwrap_or("unknown"); [INFO] [stdout] ... | [INFO] [stdout] 361 | | ... } [INFO] [stdout] | |_______________________^ [INFO] [stdout] | [INFO] [stdout] help: the outer pattern can be modified to include the inner pattern [INFO] [stdout] --> src/agents/mcp_agent.rs:303:37 [INFO] [stdout] | [INFO] [stdout] 303 | if let Some(chat_history) = memories.get("chat_history") { [INFO] [stdout] | ^^^^^^^^^^^^ replace this binding [INFO] [stdout] 304 | if let serde_json::Value::Array(messages_array) = chat_history { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ with this pattern [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/mcp/client.rs:28:24 [INFO] [stdout] | [INFO] [stdout] 28 | ...s: HashMap) -> Pin> + Send>> + Send + Sync>>, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/mcp/client.rs:130:27 [INFO] [stdout] | [INFO] [stdout] 130 | .post(&format!("{}/rpc", url)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `format!("{}/rpc", url)` [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/memory/summary.rs:172:12 [INFO] [stdout] | [INFO] [stdout] 172 | if !tokio::fs::metadata(&file_path).await.is_ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `tokio::fs::metadata(&file_path).await.is_err()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/mcp/client.rs:253:31 [INFO] [stdout] | [INFO] [stdout] 253 | .post(&format!("{}/rpc", url)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `format!("{}/rpc", url)` [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] [INFO] [stdout] [INFO] [stdout] warning: matching on `Some` with `ok()` is redundant [INFO] [stdout] --> src/memory/summary.rs:422:13 [INFO] [stdout] | [INFO] [stdout] 422 | if let Some(user_system_prompt) = std::env::var("USER_SYSTEM_PROMPT").ok() { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_result_ok [INFO] [stdout] = note: `#[warn(clippy::match_result_ok)]` on by default [INFO] [stdout] help: consider matching on `Ok(user_system_prompt)` and removing the call to `ok` instead [INFO] [stdout] | [INFO] [stdout] 422 - if let Some(user_system_prompt) = std::env::var("USER_SYSTEM_PROMPT").ok() { [INFO] [stdout] 422 + if let Ok(user_system_prompt) = std::env::var("USER_SYSTEM_PROMPT") { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual arithmetic check found [INFO] [stdout] --> src/memory/summary.rs:442:25 [INFO] [stdout] | [INFO] [stdout] 442 | let start = if len > recent_messages_count { [INFO] [stdout] | _________________________^ [INFO] [stdout] 443 | | len - recent_messages_count [INFO] [stdout] 444 | | } else { [INFO] [stdout] 445 | | 0 [INFO] [stdout] 446 | | }; [INFO] [stdout] | |_____________^ help: replace it with: `len.saturating_sub(recent_messages_count)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_saturating_sub [INFO] [stdout] = note: `#[warn(clippy::implicit_saturating_sub)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `SimpleMcpServer` [INFO] [stdout] --> src/mcp/server.rs:37:5 [INFO] [stdout] | [INFO] [stdout] 37 | / pub fn new() -> Self { [INFO] [stdout] 38 | | Self { [INFO] [stdout] 39 | | address: "127.0.0.1:6000".to_string(), [INFO] [stdout] 40 | | tools: Arc::new(Mutex::new(HashMap::new())), [INFO] [stdout] ... | [INFO] [stdout] 44 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 36 + impl Default for SimpleMcpServer { [INFO] [stdout] 37 + fn default() -> Self { [INFO] [stdout] 38 + Self::new() [INFO] [stdout] 39 + } [INFO] [stdout] 40 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for cloning elements [INFO] [stdout] --> src/lib.rs:51:36 [INFO] [stdout] | [INFO] [stdout] 51 | ... Ok(finish.return_values.get("answer").map(|s| s.clone()).unwrap_or_else(|| "".to_string())) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `cloned` method: `finish.return_values.get("answer").cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for cloning elements [INFO] [stdout] --> src/lib.rs:68:16 [INFO] [stdout] | [INFO] [stdout] 68 | Ok(finish.return_values.get("answer").map(|s| s.clone()).unwrap_or_else(|| "".to_string())) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `cloned` method: `finish.return_values.get("answer").cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant closure [INFO] [stdout] --> src/memory/composite_memory.rs:96:29 [INFO] [stdout] | [INFO] [stdout] 96 | .unwrap_or_else(|| generate_session_id()); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `generate_session_id` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure [INFO] [stdout] = note: `#[warn(clippy::redundant_closure)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default() [INFO] [stdout] --> src/memory/composite_memory.rs:126:9 [INFO] [stdout] | [INFO] [stdout] 126 | config.session_id = Some(session_id); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: consider initializing the variable with `memory::composite_memory::CompositeMemoryConfig { session_id: Some(session_id), ..Default::default() }` and removing relevant reassignments [INFO] [stdout] --> src/memory/composite_memory.rs:125:9 [INFO] [stdout] | [INFO] [stdout] 125 | let mut config = CompositeMemoryConfig::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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field assignment outside of initializer for an instance created with Default::default() [INFO] [stdout] --> src/memory/composite_memory.rs:445:9 [INFO] [stdout] | [INFO] [stdout] 445 | config.data_dir = temp_dir.path().to_path_buf(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: consider initializing the variable with `memory::composite_memory::CompositeMemoryConfig { data_dir: temp_dir.path().to_path_buf(), auto_generate_summary: false, ..Default::default() }` and removing relevant reassignments [INFO] [stdout] --> src/memory/composite_memory.rs:444:9 [INFO] [stdout] | [INFO] [stdout] 444 | let mut config = CompositeMemoryConfig::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: field assignment outside of initializer for an instance created with Default::default() [INFO] [stdout] --> src/memory/composite_memory.rs:469:9 [INFO] [stdout] | [INFO] [stdout] 469 | config.data_dir = temp_dir.path().to_path_buf(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: consider initializing the variable with `memory::composite_memory::CompositeMemoryConfig { data_dir: temp_dir.path().to_path_buf(), auto_generate_summary: false, ..Default::default() }` and removing relevant reassignments [INFO] [stdout] --> src/memory/composite_memory.rs:468:9 [INFO] [stdout] | [INFO] [stdout] 468 | let mut config = CompositeMemoryConfig::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: field assignment outside of initializer for an instance created with Default::default() [INFO] [stdout] --> src/memory/composite_memory.rs:491:9 [INFO] [stdout] | [INFO] [stdout] 491 | config.data_dir = temp_dir.path().to_path_buf(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: consider initializing the variable with `memory::composite_memory::CompositeMemoryConfig { data_dir: temp_dir.path().to_path_buf(), auto_generate_summary: false, ..Default::default() }` and removing relevant reassignments [INFO] [stdout] --> src/memory/composite_memory.rs:490:9 [INFO] [stdout] | [INFO] [stdout] 490 | let mut config = CompositeMemoryConfig::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: you should consider adding a `Default` implementation for `SimpleAgent` [INFO] [stdout] --> src/agents/agent.rs:67:5 [INFO] [stdout] | [INFO] [stdout] 67 | / pub fn new() -> Self { [INFO] [stdout] 68 | | Self { [INFO] [stdout] 69 | | tools: Vec::new(), [INFO] [stdout] 70 | | } [INFO] [stdout] 71 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 66 + impl Default for SimpleAgent { [INFO] [stdout] 67 + fn default() -> Self { [INFO] [stdout] 68 + Self::new() [INFO] [stdout] 69 + } [INFO] [stdout] 70 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you seem to be trying to use `&Box`. Consider using just `&T` [INFO] [stdout] --> src/agents/mcp_agent.rs:68:40 [INFO] [stdout] | [INFO] [stdout] 68 | pub fn get_memory(&self) -> Option<&Box> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: try: `&dyn BaseMemory` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrowed_box [INFO] [stdout] = note: `#[warn(clippy::borrowed_box)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/agents/mcp_agent.rs:459:33 [INFO] [stdout] | [INFO] [stdout] 459 | ... return Ok(AgentOutput::Action(action)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 459 - return Ok(AgentOutput::Action(action)); [INFO] [stdout] 459 + Ok(AgentOutput::Action(action)) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/agents/mcp_agent.rs:466:33 [INFO] [stdout] | [INFO] [stdout] 466 | ... return Ok(AgentOutput::Finish(AgentFinish { return_values })); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 466 - return Ok(AgentOutput::Finish(AgentFinish { return_values })); [INFO] [stdout] 466 + Ok(AgentOutput::Finish(AgentFinish { return_values })) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if let` can be collapsed into the outer `if let` [INFO] [stdout] --> src/agents/mcp_agent.rs:304:29 [INFO] [stdout] | [INFO] [stdout] 304 | / ... if let serde_json::Value::Array(messages_array) = chat_history { [INFO] [stdout] 305 | | ... for message in messages_array { [INFO] [stdout] 306 | | ... if let serde_json::Value::Object(msg_obj) = message { [INFO] [stdout] 307 | | ... let role = msg_obj.get("role").and_then(|v| v.as_str()).unwrap_or("unknown"); [INFO] [stdout] ... | [INFO] [stdout] 361 | | ... } [INFO] [stdout] | |_______________________^ [INFO] [stdout] | [INFO] [stdout] help: the outer pattern can be modified to include the inner pattern [INFO] [stdout] --> src/agents/mcp_agent.rs:303:37 [INFO] [stdout] | [INFO] [stdout] 303 | if let Some(chat_history) = memories.get("chat_history") { [INFO] [stdout] | ^^^^^^^^^^^^ replace this binding [INFO] [stdout] 304 | if let serde_json::Value::Array(messages_array) = chat_history { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ with this pattern [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: very complex type used. Consider factoring parts into `type` definitions [INFO] [stdout] --> src/mcp/client.rs:28:24 [INFO] [stdout] | [INFO] [stdout] 28 | ...s: HashMap) -> Pin> + Send>> + Send + Sync>>, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/mcp/client.rs:130:27 [INFO] [stdout] | [INFO] [stdout] 130 | .post(&format!("{}/rpc", url)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `format!("{}/rpc", url)` [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/mcp/client.rs:253:31 [INFO] [stdout] | [INFO] [stdout] 253 | .post(&format!("{}/rpc", url)) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ help: change this to: `format!("{}/rpc", url)` [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] [INFO] [stdout] [INFO] [stdout] warning: unused import: `McpTool` [INFO] [stdout] --> examples/mcp_agent_client_chatbot.rs:4:74 [INFO] [stdout] | [INFO] [stdout] 4 | use rust_agent::{run_agent, OpenAIChatModel, McpClient, SimpleMcpClient, McpTool, McpAgent, SimpleMemory, BaseMemory}; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> examples/mcp_agent_client_chatbot.rs:11:1 [INFO] [stdout] | [INFO] [stdout] 11 | use env_logger; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] = note: `#[warn(clippy::single_component_path_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `SimpleMcpServer` [INFO] [stdout] --> src/mcp/server.rs:37:5 [INFO] [stdout] | [INFO] [stdout] 37 | / pub fn new() -> Self { [INFO] [stdout] 38 | | Self { [INFO] [stdout] 39 | | address: "127.0.0.1:6000".to_string(), [INFO] [stdout] 40 | | tools: Arc::new(Mutex::new(HashMap::new())), [INFO] [stdout] ... | [INFO] [stdout] 44 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 36 + impl Default for SimpleMcpServer { [INFO] [stdout] 37 + fn default() -> Self { [INFO] [stdout] 38 + Self::new() [INFO] [stdout] 39 + } [INFO] [stdout] 40 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for cloning elements [INFO] [stdout] --> src/lib.rs:51:36 [INFO] [stdout] | [INFO] [stdout] 51 | ... Ok(finish.return_values.get("answer").map(|s| s.clone()).unwrap_or_else(|| "".to_string())) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `cloned` method: `finish.return_values.get("answer").cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] = note: `#[warn(clippy::map_clone)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you are using an explicit closure for cloning elements [INFO] [stdout] --> src/lib.rs:68:16 [INFO] [stdout] | [INFO] [stdout] 68 | Ok(finish.return_values.get("answer").map(|s| s.clone()).unwrap_or_else(|| "".to_string())) [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider calling the dedicated `cloned` method: `finish.return_values.get("answer").cloned()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#map_clone [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> examples/mcp_agent_hybrid_chatbot.rs:5:1 [INFO] [stdout] | [INFO] [stdout] 5 | use chrono; [INFO] [stdout] | ^^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] = note: `#[warn(clippy::single_component_path_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> examples/mcp_agent_hybrid_chatbot.rs:10:1 [INFO] [stdout] | [INFO] [stdout] 10 | use env_logger; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> examples/mcp_agent_hybrid_chatbot.rs:11:1 [INFO] [stdout] | [INFO] [stdout] 11 | use tokio; [INFO] [stdout] | ^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:6:1 [INFO] [stdout] | [INFO] [stdout] 6 | use chrono; [INFO] [stdout] | ^^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] = note: `#[warn(clippy::single_component_path_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this import is redundant [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:12:1 [INFO] [stdout] | [INFO] [stdout] 12 | use env_logger; [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: remove it entirely [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if let` can be collapsed into the outer `if let` [INFO] [stdout] --> examples/mcp_agent_client_chatbot.rs:174:17 [INFO] [stdout] | [INFO] [stdout] 174 | / if let serde_json::Value::Array(messages) = chat_history { [INFO] [stdout] 175 | | for (i, message) in messages.iter().enumerate() { [INFO] [stdout] 176 | | if let serde_json::Value::Object(msg) = message { [INFO] [stdout] 177 | | let role = msg.get("role").and_then(|v| v.as_str()).unwrap_or("unknown"); [INFO] [stdout] ... | [INFO] [stdout] 182 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] help: the outer pattern can be modified to include the inner pattern [INFO] [stdout] --> examples/mcp_agent_client_chatbot.rs:173:25 [INFO] [stdout] | [INFO] [stdout] 173 | if let Some(chat_history) = memories.get("chat_history") { [INFO] [stdout] | ^^^^^^^^^^^^ replace this binding [INFO] [stdout] 174 | if let serde_json::Value::Array(messages) = chat_history { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ with this pattern [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `WeatherTool` [INFO] [stdout] --> examples/mcp_server_complete_example.rs:14:5 [INFO] [stdout] | [INFO] [stdout] 14 | / pub fn new() -> Self { [INFO] [stdout] 15 | | Self { [INFO] [stdout] 16 | | name: "get_weather".to_string(), [INFO] [stdout] 17 | | description: "Get the weather information for a specified city. For example: 'What's the weather like in Beijing?'".to... [INFO] [stdout] 18 | | } [INFO] [stdout] 19 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] = note: `#[warn(clippy::new_without_default)]` on by default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 13 + impl Default for WeatherTool { [INFO] [stdout] 14 + fn default() -> Self { [INFO] [stdout] 15 + Self::new() [INFO] [stdout] 16 + } [INFO] [stdout] 17 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: you should consider adding a `Default` implementation for `CalculatorTool` [INFO] [stdout] --> examples/mcp_server_complete_example.rs:74:5 [INFO] [stdout] | [INFO] [stdout] 74 | / pub fn new() -> Self { [INFO] [stdout] 75 | | Self { [INFO] [stdout] 76 | | name: "simple_calculate".to_string(), [INFO] [stdout] 77 | | description: "Perform simple mathematical calculations. Input should be a mathematical expression with numbers and ope... [INFO] [stdout] 78 | | } [INFO] [stdout] 79 | | } [INFO] [stdout] | |_____^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default [INFO] [stdout] help: try adding this [INFO] [stdout] | [INFO] [stdout] 73 + impl Default for CalculatorTool { [INFO] [stdout] 74 + fn default() -> Self { [INFO] [stdout] 75 + Self::new() [INFO] [stdout] 76 + } [INFO] [stdout] 77 + } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> examples/mcp_server_complete_example.rs:130:43 [INFO] [stdout] | [INFO] [stdout] 130 | ... return Ok(format!("Calculation error: Invalid numbers for subtraction")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"Calculation error: Invalid numbers for subtraction".to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] = note: `#[warn(clippy::useless_format)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> examples/mcp_server_complete_example.rs:137:43 [INFO] [stdout] | [INFO] [stdout] 137 | ... return Ok(format!("Calculation error: Invalid number")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"Calculation error: Invalid number".to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless use of `format!` [INFO] [stdout] --> examples/mcp_server_complete_example.rs:159:51 [INFO] [stdout] | [INFO] [stdout] 159 | ... return Ok(format!("Calculation error: Division by zero")); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"Calculation error: Division by zero".to_string()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_format [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if let` can be collapsed into the outer `if let` [INFO] [stdout] --> examples/mcp_agent_hybrid_chatbot.rs:207:17 [INFO] [stdout] | [INFO] [stdout] 207 | / if let serde_json::Value::Array(messages) = chat_history { [INFO] [stdout] 208 | | for (i, message) in messages.iter().enumerate() { [INFO] [stdout] 209 | | if let serde_json::Value::Object(msg) = message { [INFO] [stdout] 210 | | let role = msg.get("role").and_then(|v| v.as_str()).unwrap_or("unknown"); [INFO] [stdout] ... | [INFO] [stdout] 215 | | } [INFO] [stdout] | |_________________^ [INFO] [stdout] | [INFO] [stdout] help: the outer pattern can be modified to include the inner pattern [INFO] [stdout] --> examples/mcp_agent_hybrid_chatbot.rs:206:25 [INFO] [stdout] | [INFO] [stdout] 206 | if let Some(chat_history) = memories.get("chat_history") { [INFO] [stdout] | ^^^^^^^^^^^^ replace this binding [INFO] [stdout] 207 | if let serde_json::Value::Array(messages) = chat_history { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ with this pattern [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:64:23 [INFO] [stdout] | [INFO] [stdout] 64 | "city".to_string()), [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] = note: `#[warn(clippy::to_string_in_format_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: `to_string` applied to a type that implements `Display` in `format!` args [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:71:29 [INFO] [stdout] | [INFO] [stdout] 71 | "expression".to_string()), [INFO] [stdout] | ^^^^^^^^^^^^ help: remove this [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: empty string literal in `println!` [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:189:9 [INFO] [stdout] | [INFO] [stdout] 189 | println!(""); [INFO] [stdout] | ^^^^^^^^^--^ [INFO] [stdout] | | [INFO] [stdout] | help: remove the empty string [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#println_empty_string [INFO] [stdout] = note: `#[warn(clippy::println_empty_string)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if let` can be collapsed into the outer `if let` [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:229:21 [INFO] [stdout] | [INFO] [stdout] 229 | / if let serde_json::Value::Array(messages) = chat_history { [INFO] [stdout] 230 | | info!("总消息数: {}", messages.len()); [INFO] [stdout] 231 | | for (i, message) in messages.iter().enumerate() { [INFO] [stdout] 232 | | if let serde_json::Value::Object(msg) = message { [INFO] [stdout] ... | [INFO] [stdout] 244 | | } [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] help: the outer pattern can be modified to include the inner pattern [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:228:29 [INFO] [stdout] | [INFO] [stdout] 228 | if let Some(chat_history) = memories.get("chat_history") { [INFO] [stdout] | ^^^^^^^^^^^^ replace this binding [INFO] [stdout] 229 | if let serde_json::Value::Array(messages) = chat_history { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ with this pattern [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this `if let` can be collapsed into the outer `if let` [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:249:21 [INFO] [stdout] | [INFO] [stdout] 249 | / if let serde_json::Value::String(summary_text) = summary { [INFO] [stdout] 250 | | info!("对话摘要: {}", summary_text); [INFO] [stdout] 251 | | } [INFO] [stdout] | |_____________________^ [INFO] [stdout] | [INFO] [stdout] help: the outer pattern can be modified to include the inner pattern [INFO] [stdout] --> examples/mcp_agent_local_chatbot.rs:248:29 [INFO] [stdout] | [INFO] [stdout] 248 | if let Some(summary) = memories.get("summary") { [INFO] [stdout] | ^^^^^^^ replace this binding [INFO] [stdout] 249 | if let serde_json::Value::String(summary_text) = summary { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ with this pattern [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 30.69s [INFO] running `Command { std: "docker" "inspect" "35bae3d7c0be0374e5ccaba56a91b8ded2c9656cc5a4e9abc8948379f711dc1b", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "35bae3d7c0be0374e5ccaba56a91b8ded2c9656cc5a4e9abc8948379f711dc1b", kill_on_drop: false }` [INFO] [stdout] 35bae3d7c0be0374e5ccaba56a91b8ded2c9656cc5a4e9abc8948379f711dc1b