[INFO] cloning repository https://github.com/sdesyllas/rust-chatbot [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/sdesyllas/rust-chatbot" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsdesyllas%2Frust-chatbot", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsdesyllas%2Frust-chatbot'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] a2521b37b0eb1871b22e1d1efb87381eb37d3687 [INFO] checking sdesyllas/rust-chatbot/a2521b37b0eb1871b22e1d1efb87381eb37d3687 against master#e0e204f3e97ad5f79524b9c259dc38df606ed82c for pr-149218 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fsdesyllas%2Frust-chatbot" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/sdesyllas/rust-chatbot [INFO] finished tweaking git repo https://github.com/sdesyllas/rust-chatbot [INFO] tweaked toml for git repo https://github.com/sdesyllas/rust-chatbot written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/sdesyllas/rust-chatbot on toolchain e0e204f3e97ad5f79524b9c259dc38df606ed82c [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+e0e204f3e97ad5f79524b9c259dc38df606ed82c" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/sdesyllas/rust-chatbot 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" "+e0e204f3e97ad5f79524b9c259dc38df606ed82c" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded smawk v0.3.2 [INFO] [stderr] Downloaded async-convert v1.0.0 [INFO] [stderr] Downloaded async-openai v0.15.0 [INFO] [stderr] Downloaded ferris-says v0.3.2 [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:94a0c148923f5b2b52a63ef0eeb1882ad339ab61bce784c8077cbe41c61feb6c" "/opt/rustwide/cargo-home/bin/cargo" "+e0e204f3e97ad5f79524b9c259dc38df606ed82c" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] ad48b8ac1eac9691d43f57df4326f1a765d9c38794a02bc91dd3574d2cd8f87d [INFO] running `Command { std: "docker" "start" "-a" "ad48b8ac1eac9691d43f57df4326f1a765d9c38794a02bc91dd3574d2cd8f87d", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "ad48b8ac1eac9691d43f57df4326f1a765d9c38794a02bc91dd3574d2cd8f87d", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "ad48b8ac1eac9691d43f57df4326f1a765d9c38794a02bc91dd3574d2cd8f87d", kill_on_drop: false }` [INFO] [stdout] ad48b8ac1eac9691d43f57df4326f1a765d9c38794a02bc91dd3574d2cd8f87d [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:94a0c148923f5b2b52a63ef0eeb1882ad339ab61bce784c8077cbe41c61feb6c" "/opt/rustwide/cargo-home/bin/cargo" "+e0e204f3e97ad5f79524b9c259dc38df606ed82c" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 3bfb8b08c12b49a63f13df23f9bddaf10816487bdf80b15e9664719332a36659 [INFO] running `Command { std: "docker" "start" "-a" "3bfb8b08c12b49a63f13df23f9bddaf10816487bdf80b15e9664719332a36659", kill_on_drop: false }` [INFO] [stderr] Compiling cc v1.2.17 [INFO] [stderr] Compiling thiserror-impl v2.0.12 [INFO] [stderr] Compiling tracing-attributes v0.1.28 [INFO] [stderr] Compiling syn v1.0.109 [INFO] [stderr] Checking serde v1.0.219 [INFO] [stderr] Checking tokio-util v0.7.14 [INFO] [stderr] Compiling ucd-trie v0.1.7 [INFO] [stderr] Compiling once_cell v1.21.1 [INFO] [stderr] Checking ahash v0.7.8 [INFO] [stderr] Checking rand_chacha v0.3.1 [INFO] [stderr] Compiling async-trait v0.1.88 [INFO] [stderr] Checking dlv-list v0.3.0 [INFO] [stderr] Checking eventsource-stream v0.2.3 [INFO] [stderr] Checking instant v0.1.13 [INFO] [stderr] Checking unicode-width v0.2.0 [INFO] [stderr] Checking zeroize v1.8.1 [INFO] [stderr] Checking unicode-linebreak v0.1.5 [INFO] [stderr] Checking smawk v0.3.2 [INFO] [stderr] Checking rand v0.8.5 [INFO] [stderr] Checking yaml-rust v0.4.5 [INFO] [stderr] Checking tokio-stream v0.1.17 [INFO] [stderr] Checking hashbrown v0.12.3 [INFO] [stderr] Checking pathdiff v0.2.3 [INFO] [stderr] Checking colored v2.2.0 [INFO] [stderr] Checking textwrap v0.16.2 [INFO] [stderr] Checking ferris-says v0.3.2 [INFO] [stderr] Checking async-convert v1.0.0 [INFO] [stderr] Checking ordered-multimap v0.4.3 [INFO] [stderr] Compiling thiserror v2.0.12 [INFO] [stderr] Checking tracing v0.1.41 [INFO] [stderr] Compiling pest v2.8.0 [INFO] [stderr] Checking h2 v0.3.26 [INFO] [stderr] Compiling ring v0.17.14 [INFO] [stderr] Checking rust-ini v0.18.0 [INFO] [stderr] Checking backoff v0.4.0 [INFO] [stderr] Compiling pest_meta v2.8.0 [INFO] [stderr] Checking serde_json v1.0.140 [INFO] [stderr] Checking serde_urlencoded v0.7.1 [INFO] [stderr] Checking secrecy v0.8.0 [INFO] [stderr] Checking ron v0.7.1 [INFO] [stderr] Checking toml v0.5.11 [INFO] [stderr] Compiling rustls v0.21.12 [INFO] [stderr] Compiling darling_core v0.14.4 [INFO] [stderr] Compiling pest_generator v2.8.0 [INFO] [stderr] Checking hyper v0.14.32 [INFO] [stderr] Compiling pest_derive v2.8.0 [INFO] [stderr] Compiling darling_macro v0.14.4 [INFO] [stderr] Checking json5 v0.4.1 [INFO] [stderr] Compiling darling v0.14.4 [INFO] [stderr] Compiling derive_builder_core v0.12.0 [INFO] [stderr] Checking rustls-webpki v0.101.7 [INFO] [stderr] Checking sct v0.7.1 [INFO] [stderr] Checking config v0.13.4 [INFO] [stderr] Compiling derive_builder_macro v0.12.0 [INFO] [stderr] Checking derive_builder v0.12.0 [INFO] [stderr] Checking tokio-rustls v0.24.1 [INFO] [stderr] Checking hyper-rustls v0.24.2 [INFO] [stderr] Checking reqwest v0.11.27 [INFO] [stderr] Checking reqwest-eventsource v0.4.0 [INFO] [stderr] Checking async-openai v0.15.0 [INFO] [stderr] Checking rust-chatbot v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] error[E0432]: unresolved imports `async_openai::types::ChatCompletionRequestSystemMessage`, `async_openai::types::ChatCompletionRequestUserMessage` [INFO] [stdout] --> src/main.rs:4:39 [INFO] [stdout] | [INFO] [stdout] 4 | ChatCompletionRequestMessage, ChatCompletionRequestSystemMessage, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no `ChatCompletionRequestSystemMessage` in `types` [INFO] [stdout] 5 | ChatCompletionRequestUserMessage, CreateChatCompletionRequest, Role, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no `ChatCompletionRequestUserMessage` in `types` [INFO] [stdout] | [INFO] [stdout] help: a similar name exists in the module [INFO] [stdout] | [INFO] [stdout] 4 - ChatCompletionRequestMessage, ChatCompletionRequestSystemMessage, [INFO] [stdout] 4 + ChatCompletionRequestMessage, ChatCompletionRequestMessage, [INFO] [stdout] | [INFO] [stdout] help: a similar name exists in the module [INFO] [stdout] | [INFO] [stdout] 5 - ChatCompletionRequestUserMessage, CreateChatCompletionRequest, Role, [INFO] [stdout] 5 + ChatCompletionRequestMessage, CreateChatCompletionRequest, Role, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0422]: cannot find struct, variant or union type `ChatCompletionRequestAssistantMessage` in module `async_openai::types` [INFO] [stdout] --> src/main.rs:153:34 [INFO] [stdout] | [INFO] [stdout] 153 | async_openai::types::ChatCompletionRequestAssistantMessage { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: a struct with a similar name exists: `ChatCompletionRequestMessage` [INFO] [stdout] | [INFO] [stdout] ::: /opt/rustwide/cargo-home/registry/src/index.crates.io-1949cf8c6b5b557f/async-openai-0.15.0/src/types/types.rs:989:1 [INFO] [stdout] | [INFO] [stdout] 989 | pub struct ChatCompletionRequestMessage { [INFO] [stdout] | --------------------------------------- similarly named struct `ChatCompletionRequestMessage` defined here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:47:19 [INFO] [stdout] | [INFO] [stdout] 47 | writer.flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:46:42 [INFO] [stdout] | [INFO] [stdout] 46 | say(welcome_message, 40, &mut writer)?; [INFO] [stdout] | -------------------------------------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: the trait bound `Box: From<&str>` is not satisfied [INFO] [stdout] --> src/main.rs:61:50 [INFO] [stdout] | [INFO] [stdout] 61 | return Err("Missing API key or endpoint".into()); [INFO] [stdout] | ^^^^ the trait `From<&str>` is not implemented for `Box` [INFO] [stdout] | [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] = note: required for `&str` to implement `Into>` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0432]: unresolved imports `async_openai::types::ChatCompletionRequestSystemMessage`, `async_openai::types::ChatCompletionRequestUserMessage` [INFO] [stdout] --> src/main.rs:4:39 [INFO] [stdout] | [INFO] [stdout] 4 | ChatCompletionRequestMessage, ChatCompletionRequestSystemMessage, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no `ChatCompletionRequestSystemMessage` in `types` [INFO] [stdout] 5 | ChatCompletionRequestUserMessage, CreateChatCompletionRequest, Role, [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no `ChatCompletionRequestUserMessage` in `types` [INFO] [stdout] | [INFO] [stdout] help: a similar name exists in the module [INFO] [stdout] | [INFO] [stdout] 4 - ChatCompletionRequestMessage, ChatCompletionRequestSystemMessage, [INFO] [stdout] 4 + ChatCompletionRequestMessage, ChatCompletionRequestMessage, [INFO] [stdout] | [INFO] [stdout] help: a similar name exists in the module [INFO] [stdout] | [INFO] [stdout] 5 - ChatCompletionRequestUserMessage, CreateChatCompletionRequest, Role, [INFO] [stdout] 5 + ChatCompletionRequestMessage, CreateChatCompletionRequest, Role, [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0422]: cannot find struct, variant or union type `ChatCompletionRequestAssistantMessage` in module `async_openai::types` [INFO] [stdout] --> src/main.rs:153:34 [INFO] [stdout] | [INFO] [stdout] 153 | async_openai::types::ChatCompletionRequestAssistantMessage { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: a struct with a similar name exists: `ChatCompletionRequestMessage` [INFO] [stdout] | [INFO] [stdout] ::: /opt/rustwide/cargo-home/registry/src/index.crates.io-1949cf8c6b5b557f/async-openai-0.15.0/src/types/types.rs:989:1 [INFO] [stdout] | [INFO] [stdout] 989 | pub struct ChatCompletionRequestMessage { [INFO] [stdout] | --------------------------------------- similarly named struct `ChatCompletionRequestMessage` defined here [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no associated item named `System` found for struct `ChatCompletionRequestMessage` in the current scope [INFO] [stdout] --> src/main.rs:77:39 [INFO] [stdout] | [INFO] [stdout] 77 | ChatCompletionRequestMessage::System( [INFO] [stdout] | ^^^^^^ associated item not found in `ChatCompletionRequestMessage` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:89:29 [INFO] [stdout] | [INFO] [stdout] 89 | io::stdout().flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:92:47 [INFO] [stdout] | [INFO] [stdout] 92 | io::stdin().read_line(&mut user_input)?; [INFO] [stdout] | --------------------------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no associated item named `User` found for struct `ChatCompletionRequestMessage` in the current scope [INFO] [stdout] --> src/main.rs:102:65 [INFO] [stdout] | [INFO] [stdout] 102 | conversation_history.push(ChatCompletionRequestMessage::User( [INFO] [stdout] | ^^^^ associated item not found in `ChatCompletionRequestMessage` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:47:19 [INFO] [stdout] | [INFO] [stdout] 47 | writer.flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:46:42 [INFO] [stdout] | [INFO] [stdout] 46 | say(welcome_message, 40, &mut writer)?; [INFO] [stdout] | -------------------------------------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no function or associated item named `new` found for struct `CreateChatCompletionRequest` in the current scope [INFO] [stdout] --> src/main.rs:111:52 [INFO] [stdout] | [INFO] [stdout] 111 | let request = CreateChatCompletionRequest::new( [INFO] [stdout] | ^^^ function or associated item not found in `CreateChatCompletionRequest` [INFO] [stdout] | [INFO] [stdout] help: there is a method `ne` with a similar name, but with different arguments [INFO] [stdout] --> /rustc/e0e204f3e97ad5f79524b9c259dc38df606ed82c/library/core/src/cmp.rs:264:4 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:121:29 [INFO] [stdout] | [INFO] [stdout] 121 | io::stdout().flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: the trait bound `Box: From<&str>` is not satisfied [INFO] [stdout] --> src/main.rs:61:50 [INFO] [stdout] | [INFO] [stdout] 61 | return Err("Missing API key or endpoint".into()); [INFO] [stdout] | ^^^^ the trait `From<&str>` is not implemented for `Box` [INFO] [stdout] | [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] = note: required for `&str` to implement `Into>` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:123:68 [INFO] [stdout] | [INFO] [stdout] 123 | let mut stream = client.chat().create_stream(request).await?; [INFO] [stdout] | ------------------------------------------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, OpenAIError>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:137:49 [INFO] [stdout] | [INFO] [stdout] 137 | ... io::stdout().flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no associated item named `System` found for struct `ChatCompletionRequestMessage` in the current scope [INFO] [stdout] --> src/main.rs:77:39 [INFO] [stdout] | [INFO] [stdout] 77 | ChatCompletionRequestMessage::System( [INFO] [stdout] | ^^^^^^ associated item not found in `ChatCompletionRequestMessage` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no associated item named `Assistant` found for struct `ChatCompletionRequestMessage` in the current scope [INFO] [stdout] --> src/main.rs:152:65 [INFO] [stdout] | [INFO] [stdout] 152 | conversation_history.push(ChatCompletionRequestMessage::Assistant( [INFO] [stdout] | ^^^^^^^^^ associated item not found in `ChatCompletionRequestMessage` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:89:29 [INFO] [stdout] | [INFO] [stdout] 89 | io::stdout().flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:92:47 [INFO] [stdout] | [INFO] [stdout] 92 | io::stdin().read_line(&mut user_input)?; [INFO] [stdout] | --------------------------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no associated item named `User` found for struct `ChatCompletionRequestMessage` in the current scope [INFO] [stdout] --> src/main.rs:102:65 [INFO] [stdout] | [INFO] [stdout] 102 | conversation_history.push(ChatCompletionRequestMessage::User( [INFO] [stdout] | ^^^^ associated item not found in `ChatCompletionRequestMessage` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> src/main.rs:86:5 [INFO] [stdout] | [INFO] [stdout] 42 | async fn main() -> Result<(), Box> { [INFO] [stdout] | -------------------------------------- expected `Result<(), Box<(dyn StdError + 'static)>>` because of return type [INFO] [stdout] ... [INFO] [stdout] 86 | / loop { [INFO] [stdout] 87 | | // Print prompt and get user input [INFO] [stdout] 88 | | print!("{} ", "You:".blue().bold()); [INFO] [stdout] 89 | | io::stdout().flush()?; [INFO] [stdout] ... | [INFO] [stdout] 163 | | Ok(()) [INFO] [stdout] | |__________^ expected `Result<(), Box>`, found `Result<(), Box>` [INFO] [stdout] | [INFO] [stdout] = note: expected enum `Result<_, Box<(dyn StdError + 'static)>>` [INFO] [stdout] found enum `Result<_, Box>` [INFO] [stdout] = help: `ConfigError` implements `Error` so you could box the found value and coerce it to the trait object `Box`, you will have to change the expected type as well [INFO] [stdout] help: use `?` to coerce and return an appropriate `Err`, and wrap the resulting value in `Ok` so the expression remains of type `Result` [INFO] [stdout] | [INFO] [stdout] 86 ~ Ok(loop { [INFO] [stdout] 87 | // Print prompt and get user input [INFO] [stdout] ... [INFO] [stdout] 162 | [INFO] [stdout] 163 ~ Ok(())?) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no function or associated item named `new` found for struct `CreateChatCompletionRequest` in the current scope [INFO] [stdout] --> src/main.rs:111:52 [INFO] [stdout] | [INFO] [stdout] 111 | let request = CreateChatCompletionRequest::new( [INFO] [stdout] | ^^^ function or associated item not found in `CreateChatCompletionRequest` [INFO] [stdout] | [INFO] [stdout] help: there is a method `ne` with a similar name, but with different arguments [INFO] [stdout] --> /rustc/e0e204f3e97ad5f79524b9c259dc38df606ed82c/library/core/src/cmp.rs:264:4 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:121:29 [INFO] [stdout] | [INFO] [stdout] 121 | io::stdout().flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:123:68 [INFO] [stdout] | [INFO] [stdout] 123 | let mut stream = client.chat().create_stream(request).await?; [INFO] [stdout] | ------------------------------------------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, OpenAIError>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0277]: `?` couldn't convert the error to `Box` [INFO] [stdout] --> src/main.rs:137:49 [INFO] [stdout] | [INFO] [stdout] 137 | ... io::stdout().flush()?; [INFO] [stdout] | -------^ the trait `From` is not implemented for `Box` [INFO] [stdout] | | [INFO] [stdout] | this can't be annotated with `?` because it has type `Result<_, std::io::Error>` [INFO] [stdout] | [INFO] [stdout] = note: the question mark operation (`?`) implicitly performs a conversion on the error value using the `From` trait [INFO] [stdout] = help: the following other types implement trait `From`: [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&CStr>` [INFO] [stdout] `Box` implements `From<&mut CStr>` [INFO] [stdout] `Box` implements `From` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] `Box` implements `From<&OsStr>` [INFO] [stdout] `Box` implements `From<&mut OsStr>` [INFO] [stdout] `Box` implements `From>` [INFO] [stdout] and 30 others [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no associated item named `Assistant` found for struct `ChatCompletionRequestMessage` in the current scope [INFO] [stdout] --> src/main.rs:152:65 [INFO] [stdout] | [INFO] [stdout] 152 | conversation_history.push(ChatCompletionRequestMessage::Assistant( [INFO] [stdout] | ^^^^^^^^^ associated item not found in `ChatCompletionRequestMessage` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0277, E0308, E0422, E0432, E0599. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0277`. [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> src/main.rs:86:5 [INFO] [stdout] | [INFO] [stdout] 42 | async fn main() -> Result<(), Box> { [INFO] [stdout] | -------------------------------------- expected `Result<(), Box<(dyn StdError + 'static)>>` because of return type [INFO] [stdout] ... [INFO] [stdout] 86 | / loop { [INFO] [stdout] 87 | | // Print prompt and get user input [INFO] [stdout] 88 | | print!("{} ", "You:".blue().bold()); [INFO] [stdout] 89 | | io::stdout().flush()?; [INFO] [stdout] ... | [INFO] [stdout] 163 | | Ok(()) [INFO] [stdout] | |__________^ expected `Result<(), Box>`, found `Result<(), Box>` [INFO] [stdout] | [INFO] [stdout] = note: expected enum `Result<_, Box<(dyn StdError + 'static)>>` [INFO] [stdout] found enum `Result<_, Box>` [INFO] [stdout] = help: `ConfigError` implements `Error` so you could box the found value and coerce it to the trait object `Box`, you will have to change the expected type as well [INFO] [stdout] help: use `?` to coerce and return an appropriate `Err`, and wrap the resulting value in `Ok` so the expression remains of type `Result` [INFO] [stdout] | [INFO] [stdout] 86 ~ Ok(loop { [INFO] [stdout] 87 | // Print prompt and get user input [INFO] [stdout] ... [INFO] [stdout] 162 | [INFO] [stdout] 163 ~ Ok(())?) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `rust-chatbot` (bin "rust-chatbot") due to 15 previous errors [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stdout] Some errors have detailed explanations: E0277, E0308, E0422, E0432, E0599. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0277`. [INFO] [stdout] [INFO] [stderr] error: could not compile `rust-chatbot` (bin "rust-chatbot" test) due to 15 previous errors [INFO] running `Command { std: "docker" "inspect" "3bfb8b08c12b49a63f13df23f9bddaf10816487bdf80b15e9664719332a36659", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "3bfb8b08c12b49a63f13df23f9bddaf10816487bdf80b15e9664719332a36659", kill_on_drop: false }` [INFO] [stdout] 3bfb8b08c12b49a63f13df23f9bddaf10816487bdf80b15e9664719332a36659