24 lines
64 KiB
Plaintext
24 lines
64 KiB
Plaintext
{"$message_type":"diagnostic","message":"unresolved import `async_openai::types::chat::ChatCompletion`","code":{"code":"E0432","explanation":"An import was unresolved.\n\nErroneous code example:\n\n```compile_fail,E0432\nuse something::Foo; // error: unresolved import `something::Foo`.\n```\n\nIn Rust 2015, paths in `use` statements are relative to the crate root. To\nimport items relative to the current and parent modules, use the `self::` and\n`super::` prefixes, respectively.\n\nIn Rust 2018 or later, paths in `use` statements are relative to the current\nmodule unless they begin with the name of a crate or a literal `crate::`, in\nwhich case they start from the crate root. As in Rust 2015 code, the `self::`\nand `super::` prefixes refer to the current and parent modules respectively.\n\nAlso verify that you didn't misspell the import name and that the import exists\nin the module from where you tried to import it. Example:\n\n```\nuse self::something::Foo; // Ok.\n\nmod something {\n pub struct Foo;\n}\n# fn main() {}\n```\n\nIf you tried to use a module from an external crate and are using Rust 2015,\nyou may have missed the `extern crate` declaration (which is usually placed in\nthe crate root):\n\n```edition2015\nextern crate core; // Required to use the `core` crate in Rust 2015.\n\nuse core::any;\n# fn main() {}\n```\n\nSince Rust 2018 the `extern crate` declaration is not required and\nyou can instead just `use` it:\n\n```edition2018\nuse core::any; // No extern crate required in Rust 2018.\n# fn main() {}\n```\n"},"level":"error","spans":[{"file_name":"src/providers/openai.rs","byte_start":590,"byte_end":604,"line_start":4,"line_end":4,"column_start":481,"column_end":495,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, ChatCompletion};","highlight_start":481,"highlight_end":495}],"label":"no `ChatCompletion` in `types::chat`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a similar name exists in the module","code":null,"level":"help","spans":[{"file_name":"src/providers/openai.rs","byte_start":590,"byte_end":604,"line_start":4,"line_end":4,"column_start":481,"column_end":495,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, ChatCompletion};","highlight_start":481,"highlight_end":495}],"label":null,"suggested_replacement":"ChatCompletionTool","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0432]\u001b[0m\u001b[1m: unresolved import `async_openai::types::chat::ChatCompletion`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:4:481\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m4\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m...\u001b[0mContentPartImage, ImageUrl, ChatCompletion};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^^^^^^^^^\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91mno `ChatCompletion` in `types::chat`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91mhelp: a similar name exists in the module: `ChatCompletionTool`\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"unresolved import `async_openai::types::chat::ChatCompletion`","code":{"code":"E0432","explanation":"An import was unresolved.\n\nErroneous code example:\n\n```compile_fail,E0432\nuse something::Foo; // error: unresolved import `something::Foo`.\n```\n\nIn Rust 2015, paths in `use` statements are relative to the crate root. To\nimport items relative to the current and parent modules, use the `self::` and\n`super::` prefixes, respectively.\n\nIn Rust 2018 or later, paths in `use` statements are relative to the current\nmodule unless they begin with the name of a crate or a literal `crate::`, in\nwhich case they start from the crate root. As in Rust 2015 code, the `self::`\nand `super::` prefixes refer to the current and parent modules respectively.\n\nAlso verify that you didn't misspell the import name and that the import exists\nin the module from where you tried to import it. Example:\n\n```\nuse self::something::Foo; // Ok.\n\nmod something {\n pub struct Foo;\n}\n# fn main() {}\n```\n\nIf you tried to use a module from an external crate and are using Rust 2015,\nyou may have missed the `extern crate` declaration (which is usually placed in\nthe crate root):\n\n```edition2015\nextern crate core; // Required to use the `core` crate in Rust 2015.\n\nuse core::any;\n# fn main() {}\n```\n\nSince Rust 2018 the `extern crate` declaration is not required and\nyou can instead just `use` it:\n\n```edition2018\nuse core::any; // No extern crate required in Rust 2018.\n# fn main() {}\n```\n"},"level":"error","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":534,"byte_end":548,"line_start":4,"line_end":4,"column_start":425,"column_end":439,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletion};","highlight_start":425,"highlight_end":439}],"label":"no `ChatCompletion` in `types::chat`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a similar name exists in the module","code":null,"level":"help","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":534,"byte_end":548,"line_start":4,"line_end":4,"column_start":425,"column_end":439,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletion};","highlight_start":425,"highlight_end":439}],"label":null,"suggested_replacement":"ChatCompletionTool","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0432]\u001b[0m\u001b[1m: unresolved import `async_openai::types::chat::ChatCompletion`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:4:425\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m4\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m...\u001b[0muestMessageContentPartText, ChatCompletion};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^^^^^^^^^\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91mno `ChatCompletion` in `types::chat`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91mhelp: a similar name exists in the module: `ChatCompletionTool`\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"unused import: `Environment`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"src/config/mod.rs","byte_start":41,"byte_end":52,"line_start":2,"line_end":2,"column_start":22,"column_end":33,"is_primary":true,"text":[{"text":"use config::{Config, Environment, File, FileFormat};","highlight_start":22,"highlight_end":33}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"`#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"remove the unused import","code":null,"level":"help","spans":[{"file_name":"src/config/mod.rs","byte_start":39,"byte_end":52,"line_start":2,"line_end":2,"column_start":20,"column_end":33,"is_primary":true,"text":[{"text":"use config::{Config, Environment, File, FileFormat};","highlight_start":20,"highlight_end":33}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `Environment`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/config/mod.rs:2:22\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m2\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use config::{Config, Environment, File, FileFormat};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default\n\n"}
|
|
{"$message_type":"diagnostic","message":"unused import: `UnifiedMessage`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"src/providers/mod.rs","byte_start":107,"byte_end":121,"line_start":5,"line_end":5,"column_start":37,"column_end":51,"is_primary":true,"text":[{"text":"use crate::models::{UnifiedRequest, UnifiedMessage};","highlight_start":37,"highlight_end":51}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the unused import","code":null,"level":"help","spans":[{"file_name":"src/providers/mod.rs","byte_start":105,"byte_end":121,"line_start":5,"line_end":5,"column_start":35,"column_end":51,"is_primary":true,"text":[{"text":"use crate::models::{UnifiedRequest, UnifiedMessage};","highlight_start":35,"highlight_end":51}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"src/providers/mod.rs","byte_start":90,"byte_end":91,"line_start":5,"line_end":5,"column_start":20,"column_end":21,"is_primary":true,"text":[{"text":"use crate::models::{UnifiedRequest, UnifiedMessage};","highlight_start":20,"highlight_end":21}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"src/providers/mod.rs","byte_start":121,"byte_end":122,"line_start":5,"line_end":5,"column_start":51,"column_end":52,"is_primary":true,"text":[{"text":"use crate::models::{UnifiedRequest, UnifiedMessage};","highlight_start":51,"highlight_end":52}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `UnifiedMessage`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/mod.rs:5:37\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m5\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use crate::models::{UnifiedRequest, UnifiedMessage};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"unused import: `Config`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"src/providers/openai.rs","byte_start":86,"byte_end":92,"line_start":3,"line_end":3,"column_start":37,"column_end":43,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":37,"highlight_end":43}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the unused import","code":null,"level":"help","spans":[{"file_name":"src/providers/openai.rs","byte_start":86,"byte_end":94,"line_start":3,"line_end":3,"column_start":37,"column_end":45,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":37,"highlight_end":45}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"src/providers/openai.rs","byte_start":85,"byte_end":86,"line_start":3,"line_end":3,"column_start":36,"column_end":37,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":36,"highlight_end":37}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"src/providers/openai.rs","byte_start":106,"byte_end":107,"line_start":3,"line_end":3,"column_start":57,"column_end":58,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":57,"highlight_end":58}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `Config`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:3:37\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m3\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use async_openai::{Client, config::{Config, OpenAIConfig}};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"unused imports: `ChatCompletionRequestMessageContentPartImage`, `ChatCompletionRequestMessageContentPartText`, `ChatCompletionRequestUserMessageContentPart`, and `ImageUrl`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"src/providers/openai.rs","byte_start":444,"byte_end":487,"line_start":4,"line_end":4,"column_start":335,"column_end":378,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, ChatCompletion};","highlight_start":335,"highlight_end":378}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/openai.rs","byte_start":489,"byte_end":532,"line_start":4,"line_end":4,"column_start":380,"column_end":423,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, ChatCompletion};","highlight_start":380,"highlight_end":423}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/openai.rs","byte_start":534,"byte_end":578,"line_start":4,"line_end":4,"column_start":425,"column_end":469,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, ChatCompletion};","highlight_start":425,"highlight_end":469}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/openai.rs","byte_start":580,"byte_end":588,"line_start":4,"line_end":4,"column_start":471,"column_end":479,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, ChatCompletion};","highlight_start":471,"highlight_end":479}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the unused imports","code":null,"level":"help","spans":[{"file_name":"src/providers/openai.rs","byte_start":442,"byte_end":588,"line_start":4,"line_end":4,"column_start":333,"column_end":479,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, ChatCompletion};","highlight_start":333,"highlight_end":479}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused imports: `ChatCompletionRequestMessageContentPartImage`, `ChatCompletionRequestMessageContentPartText`, `ChatCompletionRequestUserMessageContentPart`, and `ImageUrl`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:4:335\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m4\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m...\u001b[0mt, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletionRequestMessageContentPartImage, ImageUrl, C\u001b[1m\u001b[94m...\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[33m^^^^^^^^\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"unused import: `Config`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":86,"byte_end":92,"line_start":3,"line_end":3,"column_start":37,"column_end":43,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":37,"highlight_end":43}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the unused import","code":null,"level":"help","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":86,"byte_end":94,"line_start":3,"line_end":3,"column_start":37,"column_end":45,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":37,"highlight_end":45}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"src/providers/deepseek.rs","byte_start":85,"byte_end":86,"line_start":3,"line_end":3,"column_start":36,"column_end":37,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":36,"highlight_end":37}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"src/providers/deepseek.rs","byte_start":106,"byte_end":107,"line_start":3,"line_end":3,"column_start":57,"column_end":58,"is_primary":true,"text":[{"text":"use async_openai::{Client, config::{Config, OpenAIConfig}};","highlight_start":57,"highlight_end":58}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `Config`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:3:37\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m3\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use async_openai::{Client, config::{Config, OpenAIConfig}};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"unused imports: `ChatCompletionRequestMessageContentPartText` and `ChatCompletionRequestUserMessageContentPart`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":444,"byte_end":487,"line_start":4,"line_end":4,"column_start":335,"column_end":378,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletion};","highlight_start":335,"highlight_end":378}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/deepseek.rs","byte_start":489,"byte_end":532,"line_start":4,"line_end":4,"column_start":380,"column_end":423,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletion};","highlight_start":380,"highlight_end":423}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the unused imports","code":null,"level":"help","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":442,"byte_end":532,"line_start":4,"line_end":4,"column_start":333,"column_end":423,"is_primary":true,"text":[{"text":"use async_openai::types::chat::{CreateChatCompletionRequestArgs, ChatCompletionRequestMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestUserMessageContent, ChatCompletionRequestSystemMessageContent, ChatCompletionRequestAssistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletion};","highlight_start":333,"highlight_end":423}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused imports: `ChatCompletionRequestMessageContentPartText` and `ChatCompletionRequestUserMessageContentPart`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:4:335\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m4\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m...\u001b[0msistantMessageContent, ChatCompletionRequestUserMessageContentPart, ChatCompletionRequestMessageContentPartText, ChatCompletion};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"lifetime parameters or bounds on associated function `from_request_parts` do not match the trait declaration","code":{"code":"E0195","explanation":"The lifetime parameters of the method do not match the trait declaration.\n\nErroneous code example:\n\n```compile_fail,E0195\ntrait Trait {\n fn bar<'a,'b:'a>(x: &'a str, y: &'b str);\n}\n\nstruct Foo;\n\nimpl Trait for Foo {\n fn bar<'a,'b>(x: &'a str, y: &'b str) {\n // error: lifetime parameters or bounds on method `bar`\n // do not match the trait declaration\n }\n}\n```\n\nThe lifetime constraint `'b` for `bar()` implementation does not match the\ntrait declaration. Ensure lifetime declarations match exactly in both trait\ndeclaration and implementation. Example:\n\n```\ntrait Trait {\n fn t<'a,'b:'a>(x: &'a str, y: &'b str);\n}\n\nstruct Foo;\n\nimpl Trait for Foo {\n fn t<'a,'b:'a>(x: &'a str, y: &'b str) { // ok!\n }\n}\n```\n"},"level":"error","spans":[{"file_name":"src/auth/mod.rs","byte_start":453,"byte_end":501,"line_start":21,"line_end":21,"column_start":14,"column_end":62,"is_primary":true,"text":[{"text":" async fn from_request_parts(parts: &mut Parts, state: &S) -> Result<Self, Self::Rejection> {","highlight_start":14,"highlight_end":62}],"label":"lifetimes do not match associated function in trait","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/home/newkirk/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/axum-core-0.5.6/src/extract/mod.rs","byte_start":1815,"byte_end":1952,"line_start":59,"line_end":62,"column_start":5,"column_end":69,"is_primary":false,"text":[{"text":" fn from_request_parts(","highlight_start":5,"highlight_end":1},{"text":" parts: &mut Parts,","highlight_start":1,"highlight_end":1},{"text":" state: &S,","highlight_start":1,"highlight_end":1},{"text":" ) -> impl Future<Output = Result<Self, Self::Rejection>> + Send;","highlight_start":1,"highlight_end":69}],"label":"lifetimes in impl do not match this associated function in trait","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0195]\u001b[0m\u001b[1m: lifetime parameters or bounds on associated function `from_request_parts` do not match the trait declaration\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/auth/mod.rs:21:14\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m21\u001b[0m \u001b[1m\u001b[94m|\u001b[0m async fn from_request_parts(parts: &mut Parts, state: &S) -> Result<Self, Self::Rejection> {\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[91mlifetimes do not match associated function in trait\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m::: \u001b[0m/home/newkirk/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/axum-core-0.5.6/src/extract/mod.rs:59:5\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m59\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m/\u001b[0m fn from_request_parts(\n\u001b[1m\u001b[94m60\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m parts: &mut Parts,\n\u001b[1m\u001b[94m61\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m state: &S,\n\u001b[1m\u001b[94m62\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m ) -> impl Future<Output = Result<Self, Self::Rejection>> + Send;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|____________________________________________________________________-\u001b[0m \u001b[1m\u001b[94mlifetimes in impl do not match this associated function in trait\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"mismatched types","code":{"code":"E0308","explanation":"Expected type did not match the received type.\n\nErroneous code examples:\n\n```compile_fail,E0308\nfn plus_one(x: i32) -> i32 {\n x + 1\n}\n\nplus_one(\"Not a number\");\n// ^^^^^^^^^^^^^^ expected `i32`, found `&str`\n\nif \"Not a bool\" {\n// ^^^^^^^^^^^^ expected `bool`, found `&str`\n}\n\nlet x: f32 = \"Not a float\";\n// --- ^^^^^^^^^^^^^ expected `f32`, found `&str`\n// |\n// expected due to this\n```\n\nThis error occurs when an expression was used in a place where the compiler\nexpected an expression of a different type. It can occur in several cases, the\nmost common being when calling a function and passing an argument which has a\ndifferent type than the matching type in the function declaration.\n"},"level":"error","spans":[{"file_name":"src/providers/openai.rs","byte_start":3570,"byte_end":3626,"line_start":88,"line_end":88,"column_start":38,"column_end":94,"is_primary":true,"text":[{"text":" content: ChatCompletionRequestAssistantMessageContent::Text(text),","highlight_start":38,"highlight_end":94}],"label":"expected `Option<...>`, found `ChatCompletionRequestAssistantMessageContent`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"expected enum `std::option::Option<ChatCompletionRequestAssistantMessageContent>`\n found enum `ChatCompletionRequestAssistantMessageContent`","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"try wrapping the expression in `Some`","code":null,"level":"help","spans":[{"file_name":"src/providers/openai.rs","byte_start":3570,"byte_end":3570,"line_start":88,"line_end":88,"column_start":38,"column_end":38,"is_primary":true,"text":[{"text":" content: ChatCompletionRequestAssistantMessageContent::Text(text),","highlight_start":38,"highlight_end":38}],"label":null,"suggested_replacement":"Some(","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"src/providers/openai.rs","byte_start":3626,"byte_end":3626,"line_start":88,"line_end":88,"column_start":94,"column_end":94,"is_primary":true,"text":[{"text":" content: ChatCompletionRequestAssistantMessageContent::Text(text),","highlight_start":94,"highlight_end":94}],"label":null,"suggested_replacement":")","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0308]\u001b[0m\u001b[1m: mismatched types\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:88:38\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m88\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m...\u001b[0m content: ChatCompletionRequestAssistantMessageContent::Text(text),\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[91mexpected `Option<...>`, found `ChatCompletionRequestAssistantMessageContent`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: expected enum `\u001b[1m\u001b[35mstd::option::Option<\u001b[0mChatCompletionRequestAssistantMessageContent\u001b[1m\u001b[35m>\u001b[0m`\n found enum `ChatCompletionRequestAssistantMessageContent`\n\u001b[1m\u001b[96mhelp\u001b[0m: try wrapping the expression in `Some`\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m88\u001b[0m \u001b[1m\u001b[94m| \u001b[0m content: \u001b[92mSome(\u001b[0mChatCompletionRequestAssistantMessageContent::Text(text)\u001b[92m)\u001b[0m,\n \u001b[1m\u001b[94m|\u001b[0m \u001b[92m+++++\u001b[0m \u001b[92m+\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"missing fields `audio` and `function_call` in initializer of `ChatCompletionRequestAssistantMessage`","code":{"code":"E0063","explanation":"A struct's or struct-like enum variant's field was not provided.\n\nErroneous code example:\n\n```compile_fail,E0063\nstruct Foo {\n x: i32,\n y: i32,\n}\n\nfn main() {\n let x = Foo { x: 0 }; // error: missing field: `y`\n}\n```\n\nEach field should be specified exactly once. Example:\n\n```\nstruct Foo {\n x: i32,\n y: i32,\n}\n\nfn main() {\n let x = Foo { x: 0, y: 0 }; // ok!\n}\n```\n"},"level":"error","spans":[{"file_name":"src/providers/openai.rs","byte_start":3493,"byte_end":3530,"line_start":87,"line_end":87,"column_start":25,"column_end":62,"is_primary":true,"text":[{"text":" ChatCompletionRequestAssistantMessage {","highlight_start":25,"highlight_end":62}],"label":"missing `audio` and `function_call`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0063]\u001b[0m\u001b[1m: missing fields `audio` and `function_call` in initializer of `ChatCompletionRequestAssistantMessage`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:87:25\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m87\u001b[0m \u001b[1m\u001b[94m|\u001b[0m ChatCompletionRequestAssistantMessage {\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[91mmissing `audio` and `function_call`\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"no method named `chat` found for struct `async_openai::Client<C>` in the current scope","code":{"code":"E0599","explanation":"This error occurs when a method is used on a type which doesn't implement it:\n\nErroneous code example:\n\n```compile_fail,E0599\nstruct Mouth;\n\nlet x = Mouth;\nx.chocolate(); // error: no method named `chocolate` found for type `Mouth`\n // in the current scope\n```\n\nIn this case, you need to implement the `chocolate` method to fix the error:\n\n```\nstruct Mouth;\n\nimpl Mouth {\n fn chocolate(&self) { // We implement the `chocolate` method here.\n println!(\"Hmmm! I love chocolate!\");\n }\n}\n\nlet x = Mouth;\nx.chocolate(); // ok!\n```\n"},"level":"error","spans":[{"file_name":"src/providers/openai.rs","byte_start":5008,"byte_end":5033,"line_start":128,"line_end":129,"column_start":24,"column_end":14,"is_primary":false,"text":[{"text":" let response = self.client","highlight_start":24,"highlight_end":35},{"text":" .chat()","highlight_start":1,"highlight_end":14}],"label":"","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/openai.rs","byte_start":5033,"byte_end":5037,"line_start":129,"line_end":129,"column_start":14,"column_end":18,"is_primary":true,"text":[{"text":" .chat()","highlight_start":14,"highlight_end":18}],"label":"method not found in `async_openai::Client<async_openai::config::OpenAIConfig>`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0599]\u001b[0m\u001b[1m: no method named `chat` found for struct `async_openai::Client<C>` in the current scope\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:129:14\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m128\u001b[0m \u001b[1m\u001b[94m|\u001b[0m let response = self.client\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m ________________________-\u001b[0m\n\u001b[1m\u001b[94m129\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m .chat()\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m-\u001b[0m\u001b[1m\u001b[91m^^^^\u001b[0m \u001b[1m\u001b[91mmethod not found in `async_openai::Client<async_openai::config::OpenAIConfig>`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|_____________|\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"type annotations needed","code":{"code":"E0282","explanation":"The compiler could not infer a type and asked for a type annotation.\n\nErroneous code example:\n\n```compile_fail,E0282\nlet x = Vec::new();\n```\n\nThis error indicates that type inference did not result in one unique possible\ntype, and extra information is required. In most cases this can be provided\nby adding a type annotation. Sometimes you need to specify a generic type\nparameter manually.\n\nIn the example above, type `Vec` has a type parameter `T`. When calling\n`Vec::new`, barring any other later usage of the variable `x` that allows the\ncompiler to infer what type `T` is, the compiler needs to be told what it is.\n\nThe type can be specified on the variable:\n\n```\nlet x: Vec<i32> = Vec::new();\n```\n\nThe type can also be specified in the path of the expression:\n\n```\nlet x = Vec::<i32>::new();\n```\n\nIn cases with more complex types, it is not necessary to annotate the full\ntype. Once the ambiguity is resolved, the compiler can infer the rest:\n\n```\nlet x: Vec<_> = \"hello\".chars().rev().collect();\n```\n\nAnother way to provide the compiler with enough information, is to specify the\ngeneric type parameter:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<char>>();\n```\n\nAgain, you need not specify the full type if the compiler can infer it:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<_>>();\n```\n\nApart from a method or function with a generic type parameter, this error can\noccur when a type parameter of a struct or trait cannot be inferred. In that\ncase it is not always possible to use a type annotation, because all candidates\nhave the same return type. For instance:\n\n```compile_fail,E0282\nstruct Foo<T> {\n num: T,\n}\n\nimpl<T> Foo<T> {\n fn bar() -> i32 {\n 0\n }\n\n fn baz() {\n let number = Foo::bar();\n }\n}\n```\n\nThis will fail because the compiler does not know which instance of `Foo` to\ncall `bar` on. Change `Foo::bar()` to `Foo::<T>::bar()` to resolve the error.\n"},"level":"error","spans":[{"file_name":"src/providers/openai.rs","byte_start":5008,"byte_end":5153,"line_start":128,"line_end":131,"column_start":24,"column_end":19,"is_primary":true,"text":[{"text":" let response = self.client","highlight_start":24,"highlight_end":35},{"text":" .chat()","highlight_start":1,"highlight_end":20},{"text":" .create(request_args.build().map_err(|e| AppError::ProviderError(e.to_string()))?)","highlight_start":1,"highlight_end":95},{"text":" .await","highlight_start":1,"highlight_end":19}],"label":"cannot infer type","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0282]\u001b[0m\u001b[1m: type annotations needed\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:128:24\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m128\u001b[0m \u001b[1m\u001b[94m|\u001b[0m let response = self.client\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m ________________________^\u001b[0m\n\u001b[1m\u001b[94m129\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m .chat()\n\u001b[1m\u001b[94m130\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m .create(request_args.build().map_err(|e| AppError::ProviderError(e.to_string()))?)\n\u001b[1m\u001b[94m131\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m .await\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|__________________^\u001b[0m \u001b[1m\u001b[91mcannot infer type\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"type annotations needed","code":{"code":"E0282","explanation":"The compiler could not infer a type and asked for a type annotation.\n\nErroneous code example:\n\n```compile_fail,E0282\nlet x = Vec::new();\n```\n\nThis error indicates that type inference did not result in one unique possible\ntype, and extra information is required. In most cases this can be provided\nby adding a type annotation. Sometimes you need to specify a generic type\nparameter manually.\n\nIn the example above, type `Vec` has a type parameter `T`. When calling\n`Vec::new`, barring any other later usage of the variable `x` that allows the\ncompiler to infer what type `T` is, the compiler needs to be told what it is.\n\nThe type can be specified on the variable:\n\n```\nlet x: Vec<i32> = Vec::new();\n```\n\nThe type can also be specified in the path of the expression:\n\n```\nlet x = Vec::<i32>::new();\n```\n\nIn cases with more complex types, it is not necessary to annotate the full\ntype. Once the ambiguity is resolved, the compiler can infer the rest:\n\n```\nlet x: Vec<_> = \"hello\".chars().rev().collect();\n```\n\nAnother way to provide the compiler with enough information, is to specify the\ngeneric type parameter:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<char>>();\n```\n\nAgain, you need not specify the full type if the compiler can infer it:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<_>>();\n```\n\nApart from a method or function with a generic type parameter, this error can\noccur when a type parameter of a struct or trait cannot be inferred. In that\ncase it is not always possible to use a type annotation, because all candidates\nhave the same return type. For instance:\n\n```compile_fail,E0282\nstruct Foo<T> {\n num: T,\n}\n\nimpl<T> Foo<T> {\n fn bar() -> i32 {\n 0\n }\n\n fn baz() {\n let number = Foo::bar();\n }\n}\n```\n\nThis will fail because the compiler does not know which instance of `Foo` to\ncall `bar` on. Change `Foo::bar()` to `Foo::<T>::bar()` to resolve the error.\n"},"level":"error","spans":[{"file_name":"src/providers/openai.rs","byte_start":5203,"byte_end":5204,"line_start":132,"line_end":132,"column_start":50,"column_end":51,"is_primary":false,"text":[{"text":" .map_err(|e| AppError::ProviderError(e.to_string()))?;","highlight_start":50,"highlight_end":51}],"label":"type must be known at this point","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/openai.rs","byte_start":5176,"byte_end":5177,"line_start":132,"line_end":132,"column_start":23,"column_end":24,"is_primary":true,"text":[{"text":" .map_err(|e| AppError::ProviderError(e.to_string()))?;","highlight_start":23,"highlight_end":24}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"consider giving this closure parameter an explicit type","code":null,"level":"help","spans":[{"file_name":"src/providers/openai.rs","byte_start":5177,"byte_end":5177,"line_start":132,"line_end":132,"column_start":24,"column_end":24,"is_primary":true,"text":[{"text":" .map_err(|e| AppError::ProviderError(e.to_string()))?;","highlight_start":24,"highlight_end":24}],"label":null,"suggested_replacement":": /* Type */","suggestion_applicability":"HasPlaceholders","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0282]\u001b[0m\u001b[1m: type annotations needed\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/openai.rs:132:23\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m132\u001b[0m \u001b[1m\u001b[94m|\u001b[0m .map_err(|e| AppError::ProviderError(e.to_string()))?;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^\u001b[0m \u001b[1m\u001b[94m-\u001b[0m \u001b[1m\u001b[94mtype must be known at this point\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[96mhelp\u001b[0m: consider giving this closure parameter an explicit type\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m132\u001b[0m \u001b[1m\u001b[94m| \u001b[0m .map_err(|e\u001b[92m: /* Type */\u001b[0m| AppError::ProviderError(e.to_string()))?;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[92m++++++++++++\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"mismatched types","code":{"code":"E0308","explanation":"Expected type did not match the received type.\n\nErroneous code examples:\n\n```compile_fail,E0308\nfn plus_one(x: i32) -> i32 {\n x + 1\n}\n\nplus_one(\"Not a number\");\n// ^^^^^^^^^^^^^^ expected `i32`, found `&str`\n\nif \"Not a bool\" {\n// ^^^^^^^^^^^^ expected `bool`, found `&str`\n}\n\nlet x: f32 = \"Not a float\";\n// --- ^^^^^^^^^^^^^ expected `f32`, found `&str`\n// |\n// expected due to this\n```\n\nThis error occurs when an expression was used in a place where the compiler\nexpected an expression of a different type. It can occur in several cases, the\nmost common being when calling a function and passing an argument which has a\ndifferent type than the matching type in the function declaration.\n"},"level":"error","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":3525,"byte_end":3581,"line_start":87,"line_end":87,"column_start":38,"column_end":94,"is_primary":true,"text":[{"text":" content: ChatCompletionRequestAssistantMessageContent::Text(text),","highlight_start":38,"highlight_end":94}],"label":"expected `Option<...>`, found `ChatCompletionRequestAssistantMessageContent`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"expected enum `std::option::Option<ChatCompletionRequestAssistantMessageContent>`\n found enum `ChatCompletionRequestAssistantMessageContent`","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"try wrapping the expression in `Some`","code":null,"level":"help","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":3525,"byte_end":3525,"line_start":87,"line_end":87,"column_start":38,"column_end":38,"is_primary":true,"text":[{"text":" content: ChatCompletionRequestAssistantMessageContent::Text(text),","highlight_start":38,"highlight_end":38}],"label":null,"suggested_replacement":"Some(","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"src/providers/deepseek.rs","byte_start":3581,"byte_end":3581,"line_start":87,"line_end":87,"column_start":94,"column_end":94,"is_primary":true,"text":[{"text":" content: ChatCompletionRequestAssistantMessageContent::Text(text),","highlight_start":94,"highlight_end":94}],"label":null,"suggested_replacement":")","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0308]\u001b[0m\u001b[1m: mismatched types\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:87:38\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m87\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m...\u001b[0m content: ChatCompletionRequestAssistantMessageContent::Text(text),\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[91mexpected `Option<...>`, found `ChatCompletionRequestAssistantMessageContent`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: expected enum `\u001b[1m\u001b[35mstd::option::Option<\u001b[0mChatCompletionRequestAssistantMessageContent\u001b[1m\u001b[35m>\u001b[0m`\n found enum `ChatCompletionRequestAssistantMessageContent`\n\u001b[1m\u001b[96mhelp\u001b[0m: try wrapping the expression in `Some`\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m87\u001b[0m \u001b[1m\u001b[94m| \u001b[0m content: \u001b[92mSome(\u001b[0mChatCompletionRequestAssistantMessageContent::Text(text)\u001b[92m)\u001b[0m,\n \u001b[1m\u001b[94m|\u001b[0m \u001b[92m+++++\u001b[0m \u001b[92m+\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"missing fields `audio` and `function_call` in initializer of `ChatCompletionRequestAssistantMessage`","code":{"code":"E0063","explanation":"A struct's or struct-like enum variant's field was not provided.\n\nErroneous code example:\n\n```compile_fail,E0063\nstruct Foo {\n x: i32,\n y: i32,\n}\n\nfn main() {\n let x = Foo { x: 0 }; // error: missing field: `y`\n}\n```\n\nEach field should be specified exactly once. Example:\n\n```\nstruct Foo {\n x: i32,\n y: i32,\n}\n\nfn main() {\n let x = Foo { x: 0, y: 0 }; // ok!\n}\n```\n"},"level":"error","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":3448,"byte_end":3485,"line_start":86,"line_end":86,"column_start":25,"column_end":62,"is_primary":true,"text":[{"text":" ChatCompletionRequestAssistantMessage {","highlight_start":25,"highlight_end":62}],"label":"missing `audio` and `function_call`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0063]\u001b[0m\u001b[1m: missing fields `audio` and `function_call` in initializer of `ChatCompletionRequestAssistantMessage`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:86:25\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m86\u001b[0m \u001b[1m\u001b[94m|\u001b[0m ChatCompletionRequestAssistantMessage {\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[91mmissing `audio` and `function_call`\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"no method named `chat` found for struct `async_openai::Client<C>` in the current scope","code":{"code":"E0599","explanation":"This error occurs when a method is used on a type which doesn't implement it:\n\nErroneous code example:\n\n```compile_fail,E0599\nstruct Mouth;\n\nlet x = Mouth;\nx.chocolate(); // error: no method named `chocolate` found for type `Mouth`\n // in the current scope\n```\n\nIn this case, you need to implement the `chocolate` method to fix the error:\n\n```\nstruct Mouth;\n\nimpl Mouth {\n fn chocolate(&self) { // We implement the `chocolate` method here.\n println!(\"Hmmm! I love chocolate!\");\n }\n}\n\nlet x = Mouth;\nx.chocolate(); // ok!\n```\n"},"level":"error","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":4963,"byte_end":4988,"line_start":127,"line_end":128,"column_start":24,"column_end":14,"is_primary":false,"text":[{"text":" let response = self.client","highlight_start":24,"highlight_end":35},{"text":" .chat()","highlight_start":1,"highlight_end":14}],"label":"","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/deepseek.rs","byte_start":4988,"byte_end":4992,"line_start":128,"line_end":128,"column_start":14,"column_end":18,"is_primary":true,"text":[{"text":" .chat()","highlight_start":14,"highlight_end":18}],"label":"method not found in `async_openai::Client<async_openai::config::OpenAIConfig>`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0599]\u001b[0m\u001b[1m: no method named `chat` found for struct `async_openai::Client<C>` in the current scope\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:128:14\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m127\u001b[0m \u001b[1m\u001b[94m|\u001b[0m let response = self.client\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m ________________________-\u001b[0m\n\u001b[1m\u001b[94m128\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m .chat()\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m-\u001b[0m\u001b[1m\u001b[91m^^^^\u001b[0m \u001b[1m\u001b[91mmethod not found in `async_openai::Client<async_openai::config::OpenAIConfig>`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|_____________|\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"type annotations needed","code":{"code":"E0282","explanation":"The compiler could not infer a type and asked for a type annotation.\n\nErroneous code example:\n\n```compile_fail,E0282\nlet x = Vec::new();\n```\n\nThis error indicates that type inference did not result in one unique possible\ntype, and extra information is required. In most cases this can be provided\nby adding a type annotation. Sometimes you need to specify a generic type\nparameter manually.\n\nIn the example above, type `Vec` has a type parameter `T`. When calling\n`Vec::new`, barring any other later usage of the variable `x` that allows the\ncompiler to infer what type `T` is, the compiler needs to be told what it is.\n\nThe type can be specified on the variable:\n\n```\nlet x: Vec<i32> = Vec::new();\n```\n\nThe type can also be specified in the path of the expression:\n\n```\nlet x = Vec::<i32>::new();\n```\n\nIn cases with more complex types, it is not necessary to annotate the full\ntype. Once the ambiguity is resolved, the compiler can infer the rest:\n\n```\nlet x: Vec<_> = \"hello\".chars().rev().collect();\n```\n\nAnother way to provide the compiler with enough information, is to specify the\ngeneric type parameter:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<char>>();\n```\n\nAgain, you need not specify the full type if the compiler can infer it:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<_>>();\n```\n\nApart from a method or function with a generic type parameter, this error can\noccur when a type parameter of a struct or trait cannot be inferred. In that\ncase it is not always possible to use a type annotation, because all candidates\nhave the same return type. For instance:\n\n```compile_fail,E0282\nstruct Foo<T> {\n num: T,\n}\n\nimpl<T> Foo<T> {\n fn bar() -> i32 {\n 0\n }\n\n fn baz() {\n let number = Foo::bar();\n }\n}\n```\n\nThis will fail because the compiler does not know which instance of `Foo` to\ncall `bar` on. Change `Foo::bar()` to `Foo::<T>::bar()` to resolve the error.\n"},"level":"error","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":4963,"byte_end":5108,"line_start":127,"line_end":130,"column_start":24,"column_end":19,"is_primary":true,"text":[{"text":" let response = self.client","highlight_start":24,"highlight_end":35},{"text":" .chat()","highlight_start":1,"highlight_end":20},{"text":" .create(request_args.build().map_err(|e| AppError::ProviderError(e.to_string()))?)","highlight_start":1,"highlight_end":95},{"text":" .await","highlight_start":1,"highlight_end":19}],"label":"cannot infer type","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0282]\u001b[0m\u001b[1m: type annotations needed\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:127:24\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m127\u001b[0m \u001b[1m\u001b[94m|\u001b[0m let response = self.client\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m ________________________^\u001b[0m\n\u001b[1m\u001b[94m128\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m .chat()\n\u001b[1m\u001b[94m129\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m .create(request_args.build().map_err(|e| AppError::ProviderError(e.to_string()))?)\n\u001b[1m\u001b[94m130\u001b[0m \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|\u001b[0m .await\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m|__________________^\u001b[0m \u001b[1m\u001b[91mcannot infer type\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"type annotations needed","code":{"code":"E0282","explanation":"The compiler could not infer a type and asked for a type annotation.\n\nErroneous code example:\n\n```compile_fail,E0282\nlet x = Vec::new();\n```\n\nThis error indicates that type inference did not result in one unique possible\ntype, and extra information is required. In most cases this can be provided\nby adding a type annotation. Sometimes you need to specify a generic type\nparameter manually.\n\nIn the example above, type `Vec` has a type parameter `T`. When calling\n`Vec::new`, barring any other later usage of the variable `x` that allows the\ncompiler to infer what type `T` is, the compiler needs to be told what it is.\n\nThe type can be specified on the variable:\n\n```\nlet x: Vec<i32> = Vec::new();\n```\n\nThe type can also be specified in the path of the expression:\n\n```\nlet x = Vec::<i32>::new();\n```\n\nIn cases with more complex types, it is not necessary to annotate the full\ntype. Once the ambiguity is resolved, the compiler can infer the rest:\n\n```\nlet x: Vec<_> = \"hello\".chars().rev().collect();\n```\n\nAnother way to provide the compiler with enough information, is to specify the\ngeneric type parameter:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<char>>();\n```\n\nAgain, you need not specify the full type if the compiler can infer it:\n\n```\nlet x = \"hello\".chars().rev().collect::<Vec<_>>();\n```\n\nApart from a method or function with a generic type parameter, this error can\noccur when a type parameter of a struct or trait cannot be inferred. In that\ncase it is not always possible to use a type annotation, because all candidates\nhave the same return type. For instance:\n\n```compile_fail,E0282\nstruct Foo<T> {\n num: T,\n}\n\nimpl<T> Foo<T> {\n fn bar() -> i32 {\n 0\n }\n\n fn baz() {\n let number = Foo::bar();\n }\n}\n```\n\nThis will fail because the compiler does not know which instance of `Foo` to\ncall `bar` on. Change `Foo::bar()` to `Foo::<T>::bar()` to resolve the error.\n"},"level":"error","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":5158,"byte_end":5159,"line_start":131,"line_end":131,"column_start":50,"column_end":51,"is_primary":false,"text":[{"text":" .map_err(|e| AppError::ProviderError(e.to_string()))?;","highlight_start":50,"highlight_end":51}],"label":"type must be known at this point","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/providers/deepseek.rs","byte_start":5131,"byte_end":5132,"line_start":131,"line_end":131,"column_start":23,"column_end":24,"is_primary":true,"text":[{"text":" .map_err(|e| AppError::ProviderError(e.to_string()))?;","highlight_start":23,"highlight_end":24}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"consider giving this closure parameter an explicit type","code":null,"level":"help","spans":[{"file_name":"src/providers/deepseek.rs","byte_start":5132,"byte_end":5132,"line_start":131,"line_end":131,"column_start":24,"column_end":24,"is_primary":true,"text":[{"text":" .map_err(|e| AppError::ProviderError(e.to_string()))?;","highlight_start":24,"highlight_end":24}],"label":null,"suggested_replacement":": /* Type */","suggestion_applicability":"HasPlaceholders","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0282]\u001b[0m\u001b[1m: type annotations needed\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/providers/deepseek.rs:131:23\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m131\u001b[0m \u001b[1m\u001b[94m|\u001b[0m .map_err(|e| AppError::ProviderError(e.to_string()))?;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^\u001b[0m \u001b[1m\u001b[94m-\u001b[0m \u001b[1m\u001b[94mtype must be known at this point\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[96mhelp\u001b[0m: consider giving this closure parameter an explicit type\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m131\u001b[0m \u001b[1m\u001b[94m| \u001b[0m .map_err(|e\u001b[92m: /* Type */\u001b[0m| AppError::ProviderError(e.to_string()))?;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[92m++++++++++++\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"mismatched types","code":{"code":"E0308","explanation":"Expected type did not match the received type.\n\nErroneous code examples:\n\n```compile_fail,E0308\nfn plus_one(x: i32) -> i32 {\n x + 1\n}\n\nplus_one(\"Not a number\");\n// ^^^^^^^^^^^^^^ expected `i32`, found `&str`\n\nif \"Not a bool\" {\n// ^^^^^^^^^^^^ expected `bool`, found `&str`\n}\n\nlet x: f32 = \"Not a float\";\n// --- ^^^^^^^^^^^^^ expected `f32`, found `&str`\n// |\n// expected due to this\n```\n\nThis error occurs when an expression was used in a place where the compiler\nexpected an expression of a different type. It can occur in several cases, the\nmost common being when calling a function and passing an argument which has a\ndifferent type than the matching type in the function declaration.\n"},"level":"error","spans":[{"file_name":"src/main.rs","byte_start":2763,"byte_end":2770,"line_start":82,"line_end":82,"column_start":21,"column_end":28,"is_primary":true,"text":[{"text":" .with_state(db_pool);","highlight_start":21,"highlight_end":28}],"label":"expected `()`, found `Pool<Sqlite>`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"src/main.rs","byte_start":2752,"byte_end":2762,"line_start":82,"line_end":82,"column_start":10,"column_end":20,"is_primary":false,"text":[{"text":" .with_state(db_pool);","highlight_start":10,"highlight_end":20}],"label":"arguments to this method are incorrect","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"expected unit type `()`\n found struct `Pool<Sqlite>`","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"method defined here","code":null,"level":"note","spans":[{"file_name":"/home/newkirk/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/axum-0.8.8/src/routing/mod.rs","byte_start":13521,"byte_end":13531,"line_start":408,"line_end":408,"column_start":12,"column_end":22,"is_primary":true,"text":[{"text":" pub fn with_state<S2>(self, state: S) -> Router<S2> {","highlight_start":12,"highlight_end":22}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0308]\u001b[0m\u001b[1m: mismatched types\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0msrc/main.rs:82:21\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m82\u001b[0m \u001b[1m\u001b[94m|\u001b[0m .with_state(db_pool);\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m----------\u001b[0m \u001b[1m\u001b[91m^^^^^^^\u001b[0m \u001b[1m\u001b[91mexpected `()`, found `Pool<Sqlite>`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94marguments to this method are incorrect\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: expected unit type `\u001b[1m\u001b[35m()\u001b[0m`\n found struct `\u001b[1m\u001b[35mPool<Sqlite>\u001b[0m`\n\u001b[1m\u001b[92mnote\u001b[0m: method defined here\n \u001b[1m\u001b[94m--> \u001b[0m/home/newkirk/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/axum-0.8.8/src/routing/mod.rs:408:12\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m408\u001b[0m \u001b[1m\u001b[94m|\u001b[0m pub fn with_state<S2>(self, state: S) -> Router<S2> {\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[92m^^^^^^^^^^\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"aborting due to 14 previous errors; 6 warnings emitted","code":null,"level":"error","spans":[],"children":[],"rendered":"\u001b[1m\u001b[91merror\u001b[0m\u001b[1m: aborting due to 14 previous errors; 6 warnings emitted\u001b[0m\n\n"}
|
|
{"$message_type":"diagnostic","message":"Some errors have detailed explanations: E0063, E0195, E0282, E0308, E0432, E0599.","code":null,"level":"failure-note","spans":[],"children":[],"rendered":"\u001b[1mSome errors have detailed explanations: E0063, E0195, E0282, E0308, E0432, E0599.\u001b[0m\n"}
|
|
{"$message_type":"diagnostic","message":"For more information about an error, try `rustc --explain E0063`.","code":null,"level":"failure-note","spans":[],"children":[],"rendered":"\u001b[1mFor more information about an error, try `rustc --explain E0063`.\u001b[0m\n"}
|