{"$message_type":"diagnostic","message":"unused import: `error`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/main.rs","byte_start":175,"byte_end":180,"line_start":6,"line_end":6,"column_start":21,"column_end":26,"is_primary":true,"text":[{"text":"use tracing::{info, error};","highlight_start":21,"highlight_end":26}],"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":"archipelago/src/main.rs","byte_start":173,"byte_end":180,"line_start":6,"line_end":6,"column_start":19,"column_end":26,"is_primary":true,"text":[{"text":"use tracing::{info, error};","highlight_start":19,"highlight_end":26}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"archipelago/src/main.rs","byte_start":168,"byte_end":169,"line_start":6,"line_end":6,"column_start":14,"column_end":15,"is_primary":true,"text":[{"text":"use tracing::{info, error};","highlight_start":14,"highlight_end":15}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"archipelago/src/main.rs","byte_start":180,"byte_end":181,"line_start":6,"line_end":6,"column_start":26,"column_end":27,"is_primary":true,"text":[{"text":"use tracing::{info, error};","highlight_start":26,"highlight_end":27}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `error`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/main.rs:6:21\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m6\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use tracing::{info, error};\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: `hyper_util::rt::TokioIo`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/api/handler.rs","byte_start":197,"byte_end":220,"line_start":7,"line_end":7,"column_start":5,"column_end":28,"is_primary":true,"text":[{"text":"use hyper_util::rt::TokioIo;","highlight_start":5,"highlight_end":28}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the whole `use` item","code":null,"level":"help","spans":[{"file_name":"archipelago/src/api/handler.rs","byte_start":193,"byte_end":222,"line_start":7,"line_end":8,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"use hyper_util::rt::TokioIo;","highlight_start":1,"highlight_end":29},{"text":"use std::sync::Arc;","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `hyper_util::rt::TokioIo`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/api/handler.rs:7:5\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m7\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use hyper_util::rt::TokioIo;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `tokio::sync::RwLock`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/api/rpc.rs","byte_start":272,"byte_end":291,"line_start":9,"line_end":9,"column_start":5,"column_end":24,"is_primary":true,"text":[{"text":"use tokio::sync::RwLock;","highlight_start":5,"highlight_end":24}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the whole `use` item","code":null,"level":"help","spans":[{"file_name":"archipelago/src/api/rpc.rs","byte_start":268,"byte_end":293,"line_start":9,"line_end":10,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"use tokio::sync::RwLock;","highlight_start":1,"highlight_end":25},{"text":"use tracing::{debug, error};","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `tokio::sync::RwLock`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/api/rpc.rs:9:5\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m9\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use tokio::sync::RwLock;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `rpc::RpcHandler`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/api/mod.rs","byte_start":60,"byte_end":75,"line_start":5,"line_end":5,"column_start":9,"column_end":24,"is_primary":true,"text":[{"text":"pub use rpc::RpcHandler;","highlight_start":9,"highlight_end":24}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the whole `use` item","code":null,"level":"help","spans":[{"file_name":"archipelago/src/api/mod.rs","byte_start":52,"byte_end":77,"line_start":5,"line_end":5,"column_start":1,"column_end":26,"is_primary":true,"text":[{"text":"pub use rpc::RpcHandler;","highlight_start":1,"highlight_end":26}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `rpc::RpcHandler`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/api/mod.rs:5:9\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m5\u001b[0m \u001b[1m\u001b[94m|\u001b[0m pub use rpc::RpcHandler;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `Path`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/container/data_manager.rs","byte_start":47,"byte_end":51,"line_start":2,"line_end":2,"column_start":17,"column_end":21,"is_primary":true,"text":[{"text":"use std::path::{Path, PathBuf};","highlight_start":17,"highlight_end":21}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the unused import","code":null,"level":"help","spans":[{"file_name":"archipelago/src/container/data_manager.rs","byte_start":47,"byte_end":53,"line_start":2,"line_end":2,"column_start":17,"column_end":23,"is_primary":true,"text":[{"text":"use std::path::{Path, PathBuf};","highlight_start":17,"highlight_end":23}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"archipelago/src/container/data_manager.rs","byte_start":46,"byte_end":47,"line_start":2,"line_end":2,"column_start":16,"column_end":17,"is_primary":true,"text":[{"text":"use std::path::{Path, PathBuf};","highlight_start":16,"highlight_end":17}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"archipelago/src/container/data_manager.rs","byte_start":60,"byte_end":61,"line_start":2,"line_end":2,"column_start":30,"column_end":31,"is_primary":true,"text":[{"text":"use std::path::{Path, PathBuf};","highlight_start":30,"highlight_end":31}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `Path`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/container/data_manager.rs:2:17\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m2\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use std::path::{Path, PathBuf};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `std::path::PathBuf`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/container/dev_orchestrator.rs","byte_start":202,"byte_end":220,"line_start":6,"line_end":6,"column_start":5,"column_end":23,"is_primary":true,"text":[{"text":"use std::path::PathBuf;","highlight_start":5,"highlight_end":23}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the whole `use` item","code":null,"level":"help","spans":[{"file_name":"archipelago/src/container/dev_orchestrator.rs","byte_start":198,"byte_end":222,"line_start":6,"line_end":7,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"use std::path::PathBuf;","highlight_start":1,"highlight_end":24},{"text":"use std::sync::Arc;","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `std::path::PathBuf`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/container/dev_orchestrator.rs:6:5\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m6\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use std::path::PathBuf;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `tokio::sync::RwLock`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/container/dev_orchestrator.rs","byte_start":246,"byte_end":265,"line_start":8,"line_end":8,"column_start":5,"column_end":24,"is_primary":true,"text":[{"text":"use tokio::sync::RwLock;","highlight_start":5,"highlight_end":24}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the whole `use` item","code":null,"level":"help","spans":[{"file_name":"archipelago/src/container/dev_orchestrator.rs","byte_start":242,"byte_end":267,"line_start":8,"line_end":9,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"use tokio::sync::RwLock;","highlight_start":1,"highlight_end":25},{"text":"","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `tokio::sync::RwLock`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/container/dev_orchestrator.rs:8:5\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m8\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use tokio::sync::RwLock;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `data_manager::DevDataManager`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/container/mod.rs","byte_start":57,"byte_end":85,"line_start":4,"line_end":4,"column_start":9,"column_end":37,"is_primary":true,"text":[{"text":"pub use data_manager::DevDataManager;","highlight_start":9,"highlight_end":37}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the whole `use` item","code":null,"level":"help","spans":[{"file_name":"archipelago/src/container/mod.rs","byte_start":49,"byte_end":87,"line_start":4,"line_end":5,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"pub use data_manager::DevDataManager;","highlight_start":1,"highlight_end":38},{"text":"pub use dev_orchestrator::DevContainerOrchestrator;","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `data_manager::DevDataManager`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/container/mod.rs:4:9\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m4\u001b[0m \u001b[1m\u001b[94m|\u001b[0m pub use data_manager::DevDataManager;\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `info`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/server.rs","byte_start":292,"byte_end":296,"line_start":10,"line_end":10,"column_start":22,"column_end":26,"is_primary":true,"text":[{"text":"use tracing::{error, info};","highlight_start":22,"highlight_end":26}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"remove the unused import","code":null,"level":"help","spans":[{"file_name":"archipelago/src/server.rs","byte_start":290,"byte_end":296,"line_start":10,"line_end":10,"column_start":20,"column_end":26,"is_primary":true,"text":[{"text":"use tracing::{error, info};","highlight_start":20,"highlight_end":26}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"archipelago/src/server.rs","byte_start":284,"byte_end":285,"line_start":10,"line_end":10,"column_start":14,"column_end":15,"is_primary":true,"text":[{"text":"use tracing::{error, info};","highlight_start":14,"highlight_end":15}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null},{"file_name":"archipelago/src/server.rs","byte_start":296,"byte_end":297,"line_start":10,"line_end":10,"column_start":26,"column_end":27,"is_primary":true,"text":[{"text":"use tracing::{error, info};","highlight_start":26,"highlight_end":27}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `info`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/server.rs:10:22\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m10\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use tracing::{error, info};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"use of unstable library feature `str_as_str`","code":{"code":"E0658","explanation":"An unstable feature was used.\n\nErroneous code example:\n\n```compile_fail,E0658\nuse std::intrinsics; // error: use of unstable library feature `core_intrinsics`\n```\n\nIf you're using a stable or a beta version of rustc, you won't be able to use\nany unstable features. In order to do so, please switch to a nightly version of\nrustc (by using [rustup]).\n\nIf you're using a nightly version of rustc, just add the corresponding feature\nto be able to use it:\n\n```\n#![feature(core_intrinsics)]\n\nuse std::intrinsics; // ok!\n```\n\n[rustup]: https://rust-lang.github.io/rustup/concepts/channels.html\n"},"level":"error","spans":[{"file_name":"archipelago/src/api/handler.rs","byte_start":1575,"byte_end":1581,"line_start":49,"line_end":49,"column_start":29,"column_end":35,"is_primary":true,"text":[{"text":" match (method, path.as_str()) {","highlight_start":29,"highlight_end":35}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"see issue #130366 for more information","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0658]\u001b[0m\u001b[1m: use of unstable library feature `str_as_str`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/api/handler.rs:49:29\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m49\u001b[0m \u001b[1m\u001b[94m|\u001b[0m match (method, path.as_str()) {\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^^\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: see issue #130366 for more information\n\n"} {"$message_type":"diagnostic","message":"cannot move out of `req` because it is borrowed","code":{"code":"E0505","explanation":"A value was moved out while it was still borrowed.\n\nErroneous code example:\n\n```compile_fail,E0505\nstruct Value {}\n\nfn borrow(val: &Value) {}\n\nfn eat(val: Value) {}\n\nfn main() {\n let x = Value{};\n let _ref_to_val: &Value = &x;\n eat(x);\n borrow(_ref_to_val);\n}\n```\n\nHere, the function `eat` takes ownership of `x`. However,\n`x` cannot be moved because the borrow to `_ref_to_val`\nneeds to last till the function `borrow`.\nTo fix that you can do a few different things:\n\n* Try to avoid moving the variable.\n* Release borrow before move.\n* Implement the `Copy` trait on the type.\n\nExamples:\n\n```\nstruct Value {}\n\nfn borrow(val: &Value) {}\n\nfn eat(val: &Value) {}\n\nfn main() {\n let x = Value{};\n\n let ref_to_val: &Value = &x;\n eat(&x); // pass by reference, if it's possible\n borrow(ref_to_val);\n}\n```\n\nOr:\n\n```\nstruct Value {}\n\nfn borrow(val: &Value) {}\n\nfn eat(val: Value) {}\n\nfn main() {\n let x = Value{};\n\n let ref_to_val: &Value = &x;\n borrow(ref_to_val);\n // ref_to_val is no longer used.\n eat(x);\n}\n```\n\nOr:\n\n```\n#[derive(Clone, Copy)] // implement Copy trait\nstruct Value {}\n\nfn borrow(val: &Value) {}\n\nfn eat(val: Value) {}\n\nfn main() {\n let x = Value{};\n let ref_to_val: &Value = &x;\n eat(x); // it will be copied here.\n borrow(ref_to_val);\n}\n```\n\nFor more information on Rust's ownership system, take a look at the\n[References & Borrowing][references-and-borrowing] section of the Book.\n\n[references-and-borrowing]: https://doc.rust-lang.org/book/ch04-02-references-and-borrowing.html\n"},"level":"error","spans":[{"file_name":"archipelago/src/api/handler.rs","byte_start":1023,"byte_end":1026,"line_start":36,"line_end":36,"column_start":29,"column_end":32,"is_primary":true,"text":[{"text":" let (parts, body) = req.into_parts();","highlight_start":29,"highlight_end":32}],"label":"move out of `req` occurs here","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"archipelago/src/api/handler.rs","byte_start":861,"byte_end":864,"line_start":32,"line_end":32,"column_start":20,"column_end":23,"is_primary":false,"text":[{"text":" let path = req.uri().path();","highlight_start":20,"highlight_end":23}],"label":"borrow of `req` occurs here","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"archipelago/src/api/handler.rs","byte_start":680,"byte_end":683,"line_start":27,"line_end":27,"column_start":43,"column_end":46,"is_primary":false,"text":[{"text":" pub async fn handle_request(&self, req: Request) -> Result>>","highlight_start":43,"highlight_end":46}],"label":"binding `req` declared here","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"archipelago/src/api/handler.rs","byte_start":1570,"byte_end":1574,"line_start":49,"line_end":49,"column_start":24,"column_end":28,"is_primary":false,"text":[{"text":" match (method, path.as_str()) {","highlight_start":24,"highlight_end":28}],"label":"borrow later used here","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[91merror[E0505]\u001b[0m\u001b[1m: cannot move out of `req` because it is borrowed\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/api/handler.rs:36:29\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m27\u001b[0m \u001b[1m\u001b[94m|\u001b[0m pub async fn handle_request(&self, req: Request) -> Result: Service<...>` is not satisfied","code":{"code":"E0277","explanation":"You tried to use a type which doesn't implement some trait in a place which\nexpected that trait.\n\nErroneous code example:\n\n```compile_fail,E0277\n// here we declare the Foo trait with a bar method\ntrait Foo {\n fn bar(&self);\n}\n\n// we now declare a function which takes an object implementing the Foo trait\nfn some_func(foo: T) {\n foo.bar();\n}\n\nfn main() {\n // we now call the method with the i32 type, which doesn't implement\n // the Foo trait\n some_func(5i32); // error: the trait bound `i32 : Foo` is not satisfied\n}\n```\n\nIn order to fix this error, verify that the type you're using does implement\nthe trait. Example:\n\n```\ntrait Foo {\n fn bar(&self);\n}\n\n// we implement the trait on the i32 type\nimpl Foo for i32 {\n fn bar(&self) {}\n}\n\nfn some_func(foo: T) {\n foo.bar(); // we can now use this method since i32 implements the\n // Foo trait\n}\n\nfn main() {\n some_func(5i32); // ok!\n}\n```\n\nOr in a generic context, an erroneous code example would look like:\n\n```compile_fail,E0277\nfn some_func(foo: T) {\n println!(\"{:?}\", foo); // error: the trait `core::fmt::Debug` is not\n // implemented for the type `T`\n}\n\nfn main() {\n // We now call the method with the i32 type,\n // which *does* implement the Debug trait.\n some_func(5i32);\n}\n```\n\nNote that the error here is in the definition of the generic function. Although\nwe only call it with a parameter that does implement `Debug`, the compiler\nstill rejects the function. It must work with all possible input types. In\norder to make this example compile, we need to restrict the generic type we're\naccepting:\n\n```\nuse std::fmt;\n\n// Restrict the input type to types that implement Debug.\nfn some_func(foo: T) {\n println!(\"{:?}\", foo);\n}\n\nfn main() {\n // Calling the method is still fine, as i32 implements Debug.\n some_func(5i32);\n\n // This would fail to compile now:\n // struct WithoutDebug;\n // some_func(WithoutDebug);\n}\n```\n\nRust only looks at the signature of the called function, as such it must\nalready specify all requirements that will be used for every type parameter.\n"},"level":"error","spans":[{"file_name":"archipelago/src/server.rs","byte_start":1801,"byte_end":1808,"line_start":58,"line_end":58,"column_start":43,"column_end":50,"is_primary":true,"text":[{"text":" .serve_connection(io, service)","highlight_start":43,"highlight_end":50}],"label":"unsatisfied trait bound","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"archipelago/src/server.rs","byte_start":1780,"byte_end":1796,"line_start":58,"line_end":58,"column_start":22,"column_end":38,"is_primary":false,"text":[{"text":" .serve_connection(io, service)","highlight_start":22,"highlight_end":38}],"label":"required by a bound introduced by this call","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"the trait `hyper::service::service::Service>` is not implemented for `ServiceFn<{closure@server.rs:43:42}, _>`","code":null,"level":"help","spans":[],"children":[],"rendered":null},{"message":"the following other types implement trait `hyper::service::service::Service`:\n `&S` implements `hyper::service::service::Service`\n `&mut S` implements `hyper::service::service::Service`\n `Arc` implements `hyper::service::service::Service`\n `Box` implements `hyper::service::service::Service`\n `Rc` implements `hyper::service::service::Service`\n `TowerToHyperService` implements `hyper::service::service::Service`\n `hyper::service::util::ServiceFn` implements `Service>`","code":null,"level":"help","spans":[],"children":[],"rendered":null},{"message":"required by a bound in `hyper_util::server::conn::auto::Builder::::serve_connection`","code":null,"level":"note","spans":[{"file_name":"/Users/tx1138/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/hyper-util-0.1.19/src/server/conn/auto/mod.rs","byte_start":5991,"byte_end":6007,"line_start":214,"line_end":214,"column_start":12,"column_end":28,"is_primary":false,"text":[{"text":" pub fn serve_connection(&self, io: I, service: S) -> Connection<'_, I, S, E>","highlight_start":12,"highlight_end":28}],"label":"required by a bound in this associated function","suggested_replacement":null,"suggestion_applicability":null,"expansion":null},{"file_name":"/Users/tx1138/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/hyper-util-0.1.19/src/server/conn/auto/mod.rs","byte_start":6091,"byte_end":6141,"line_start":216,"line_end":216,"column_start":12,"column_end":62,"is_primary":true,"text":[{"text":" S: Service, Response = Response>,","highlight_start":12,"highlight_end":62}],"label":"required by this bound in `Builder::::serve_connection`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null},{"message":"the full name for the type has been written to '/Users/tx1138/Archipelago/core/target/debug/deps/archipelago-d6e22276b7d151e0.long-type-5975222418946226519.txt'","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"consider using `--verbose` to print the full type name to the console","code":null,"level":"note","spans":[],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0277]\u001b[0m\u001b[1m: the trait bound `ServiceFn<{closure@...}, _>: Service<...>` is not satisfied\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/server.rs:58:43\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m58\u001b[0m \u001b[1m\u001b[94m|\u001b[0m .serve_connection(io, service)\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m----------------\u001b[0m \u001b[1m\u001b[91m^^^^^^^\u001b[0m \u001b[1m\u001b[91munsatisfied trait bound\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[94mrequired by a bound introduced by this call\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mhelp\u001b[0m: the trait `hyper::service::service::Service>` is not implemented for `ServiceFn<{closure@server.rs:43:42}, _>`\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mhelp\u001b[0m: the following other types implement trait `hyper::service::service::Service`:\n `&S` implements `hyper::service::service::Service`\n `&mut S` implements `hyper::service::service::Service`\n `Arc` implements `hyper::service::service::Service`\n `Box` implements `hyper::service::service::Service`\n `Rc` implements `hyper::service::service::Service`\n `TowerToHyperService` implements `hyper::service::service::Service`\n `hyper::service::util::ServiceFn` implements `Service>`\n\u001b[1m\u001b[92mnote\u001b[0m: required by a bound in `hyper_util::server::conn::auto::Builder::::serve_connection`\n \u001b[1m\u001b[94m--> \u001b[0m/Users/tx1138/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/hyper-util-0.1.19/src/server/conn/auto/mod.rs:216:12\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m214\u001b[0m \u001b[1m\u001b[94m|\u001b[0m pub fn serve_connection(&self, io: I, service: S) -> Connectio\u001b[1m\u001b[94m...\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[94m----------------\u001b[0m \u001b[1m\u001b[94mrequired by a bound in this associated function\u001b[0m\n\u001b[1m\u001b[94m215\u001b[0m \u001b[1m\u001b[94m|\u001b[0m where\n\u001b[1m\u001b[94m216\u001b[0m \u001b[1m\u001b[94m|\u001b[0m S: Service, Response = Response>,\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[92m^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[92mrequired by this bound in `Builder::::serve_connection`\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: the full name for the type has been written to '/Users/tx1138/Archipelago/core/target/debug/deps/archipelago-d6e22276b7d151e0.long-type-5975222418946226519.txt'\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: consider using `--verbose` to print the full type name to the console\n\n"} {"$message_type":"diagnostic","message":"the trait bound `ServiceFn<{closure@...}, _>: Service<...>` is not satisfied","code":{"code":"E0277","explanation":"You tried to use a type which doesn't implement some trait in a place which\nexpected that trait.\n\nErroneous code example:\n\n```compile_fail,E0277\n// here we declare the Foo trait with a bar method\ntrait Foo {\n fn bar(&self);\n}\n\n// we now declare a function which takes an object implementing the Foo trait\nfn some_func(foo: T) {\n foo.bar();\n}\n\nfn main() {\n // we now call the method with the i32 type, which doesn't implement\n // the Foo trait\n some_func(5i32); // error: the trait bound `i32 : Foo` is not satisfied\n}\n```\n\nIn order to fix this error, verify that the type you're using does implement\nthe trait. Example:\n\n```\ntrait Foo {\n fn bar(&self);\n}\n\n// we implement the trait on the i32 type\nimpl Foo for i32 {\n fn bar(&self) {}\n}\n\nfn some_func(foo: T) {\n foo.bar(); // we can now use this method since i32 implements the\n // Foo trait\n}\n\nfn main() {\n some_func(5i32); // ok!\n}\n```\n\nOr in a generic context, an erroneous code example would look like:\n\n```compile_fail,E0277\nfn some_func(foo: T) {\n println!(\"{:?}\", foo); // error: the trait `core::fmt::Debug` is not\n // implemented for the type `T`\n}\n\nfn main() {\n // We now call the method with the i32 type,\n // which *does* implement the Debug trait.\n some_func(5i32);\n}\n```\n\nNote that the error here is in the definition of the generic function. Although\nwe only call it with a parameter that does implement `Debug`, the compiler\nstill rejects the function. It must work with all possible input types. In\norder to make this example compile, we need to restrict the generic type we're\naccepting:\n\n```\nuse std::fmt;\n\n// Restrict the input type to types that implement Debug.\nfn some_func(foo: T) {\n println!(\"{:?}\", foo);\n}\n\nfn main() {\n // Calling the method is still fine, as i32 implements Debug.\n some_func(5i32);\n\n // This would fail to compile now:\n // struct WithoutDebug;\n // some_func(WithoutDebug);\n}\n```\n\nRust only looks at the signature of the called function, as such it must\nalready specify all requirements that will be used for every type parameter.\n"},"level":"error","spans":[{"file_name":"archipelago/src/server.rs","byte_start":1831,"byte_end":1836,"line_start":59,"line_end":59,"column_start":22,"column_end":27,"is_primary":true,"text":[{"text":" .await","highlight_start":22,"highlight_end":27}],"label":"unsatisfied trait bound","suggested_replacement":null,"suggestion_applicability":null,"expansion":{"span":{"file_name":"archipelago/src/server.rs","byte_start":1831,"byte_end":1836,"line_start":59,"line_end":59,"column_start":22,"column_end":27,"is_primary":false,"text":[{"text":" .await","highlight_start":22,"highlight_end":27}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null},"macro_decl_name":"desugaring of `await` expression","def_site_span":{"file_name":"archipelago/src/main.rs","byte_start":0,"byte_end":0,"line_start":1,"line_end":1,"column_start":1,"column_end":1,"is_primary":false,"text":[],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}}}],"children":[{"message":"the trait `hyper::service::service::Service>` is not implemented for `ServiceFn<{closure@server.rs:43:42}, _>`","code":null,"level":"help","spans":[],"children":[],"rendered":null},{"message":"the following other types implement trait `hyper::service::service::Service`:\n `&S` implements `hyper::service::service::Service`\n `&mut S` implements `hyper::service::service::Service`\n `Arc` implements `hyper::service::service::Service`\n `Box` implements `hyper::service::service::Service`\n `Rc` implements `hyper::service::service::Service`\n `TowerToHyperService` implements `hyper::service::service::Service`\n `hyper::service::util::ServiceFn` implements `Service>`","code":null,"level":"help","spans":[],"children":[],"rendered":null},{"message":"required for `Connection<'_, TokioIo<...>, ..., ...>` to implement `Future`","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"required for `Connection<'_, TokioIo<...>, ..., ...>` to implement `IntoFuture`","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"the full name for the type has been written to '/Users/tx1138/Archipelago/core/target/debug/deps/archipelago-d6e22276b7d151e0.long-type-5975222418946226519.txt'","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"consider using `--verbose` to print the full type name to the console","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"remove the `.await`","code":null,"level":"help","spans":[{"file_name":"archipelago/src/server.rs","byte_start":1830,"byte_end":1836,"line_start":59,"line_end":59,"column_start":21,"column_end":27,"is_primary":true,"text":[{"text":" .await","highlight_start":21,"highlight_end":27}],"label":null,"suggested_replacement":"","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[91merror[E0277]\u001b[0m\u001b[1m: the trait bound `ServiceFn<{closure@...}, _>: Service<...>` is not satisfied\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/server.rs:59:22\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m59\u001b[0m \u001b[1m\u001b[94m|\u001b[0m .await\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[91m^^^^^\u001b[0m \u001b[1m\u001b[91munsatisfied trait bound\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mhelp\u001b[0m: the trait `hyper::service::service::Service>` is not implemented for `ServiceFn<{closure@server.rs:43:42}, _>`\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mhelp\u001b[0m: the following other types implement trait `hyper::service::service::Service`:\n `&S` implements `hyper::service::service::Service`\n `&mut S` implements `hyper::service::service::Service`\n `Arc` implements `hyper::service::service::Service`\n `Box` implements `hyper::service::service::Service`\n `Rc` implements `hyper::service::service::Service`\n `TowerToHyperService` implements `hyper::service::service::Service`\n `hyper::service::util::ServiceFn` implements `Service>`\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: required for `Connection<'_, TokioIo<...>, ..., ...>` to implement `Future`\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: required for `Connection<'_, TokioIo<...>, ..., ...>` to implement `IntoFuture`\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: the full name for the type has been written to '/Users/tx1138/Archipelago/core/target/debug/deps/archipelago-d6e22276b7d151e0.long-type-5975222418946226519.txt'\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: consider using `--verbose` to print the full type name to the console\n\u001b[1m\u001b[96mhelp\u001b[0m: remove the `.await`\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m59\u001b[0m \u001b[91m- \u001b[0m \u001b[91m.await\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `BodyExt`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/api/handler.rs","byte_start":101,"byte_end":108,"line_start":4,"line_end":4,"column_start":22,"column_end":29,"is_primary":true,"text":[{"text":"use http_body_util::{BodyExt, Full};","highlight_start":22,"highlight_end":29}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `BodyExt`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/api/handler.rs:4:22\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m4\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use http_body_util::{BodyExt, Full};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused import: `BodyExt`","code":{"code":"unused_imports","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/api/rpc.rs","byte_start":127,"byte_end":134,"line_start":4,"line_end":4,"column_start":22,"column_end":29,"is_primary":true,"text":[{"text":"use http_body_util::{BodyExt, Full};","highlight_start":22,"highlight_end":29}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused import: `BodyExt`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/api/rpc.rs:4:22\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m4\u001b[0m \u001b[1m\u001b[94m|\u001b[0m use http_body_util::{BodyExt, Full};\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"unused variable: `manifest_path`","code":{"code":"unused_variables","explanation":null},"level":"warning","spans":[{"file_name":"archipelago/src/container/dev_orchestrator.rs","byte_start":2370,"byte_end":2383,"line_start":68,"line_end":68,"column_start":9,"column_end":22,"is_primary":true,"text":[{"text":" manifest_path: &str,","highlight_start":9,"highlight_end":22}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"`#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default","code":null,"level":"note","spans":[],"children":[],"rendered":null},{"message":"if this is intentional, prefix it with an underscore","code":null,"level":"help","spans":[{"file_name":"archipelago/src/container/dev_orchestrator.rs","byte_start":2370,"byte_end":2383,"line_start":68,"line_end":68,"column_start":9,"column_end":22,"is_primary":true,"text":[{"text":" manifest_path: &str,","highlight_start":9,"highlight_end":22}],"label":null,"suggested_replacement":"_manifest_path","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"\u001b[1m\u001b[33mwarning\u001b[0m\u001b[1m: unused variable: `manifest_path`\u001b[0m\n \u001b[1m\u001b[94m--> \u001b[0marchipelago/src/container/dev_orchestrator.rs:68:9\n \u001b[1m\u001b[94m|\u001b[0m\n\u001b[1m\u001b[94m68\u001b[0m \u001b[1m\u001b[94m|\u001b[0m manifest_path: &str,\n \u001b[1m\u001b[94m|\u001b[0m \u001b[1m\u001b[33m^^^^^^^^^^^^^\u001b[0m \u001b[1m\u001b[33mhelp: if this is intentional, prefix it with an underscore: `_manifest_path`\u001b[0m\n \u001b[1m\u001b[94m|\u001b[0m\n \u001b[1m\u001b[94m= \u001b[0m\u001b[1mnote\u001b[0m: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default\n\n"} {"$message_type":"diagnostic","message":"aborting due to 4 previous errors; 12 warnings emitted","code":null,"level":"error","spans":[],"children":[],"rendered":"\u001b[1m\u001b[91merror\u001b[0m\u001b[1m: aborting due to 4 previous errors; 12 warnings emitted\u001b[0m\n\n"} {"$message_type":"diagnostic","message":"Some errors have detailed explanations: E0277, E0505, E0658.","code":null,"level":"failure-note","spans":[],"children":[],"rendered":"\u001b[1mSome errors have detailed explanations: E0277, E0505, E0658.\u001b[0m\n"} {"$message_type":"diagnostic","message":"For more information about an error, try `rustc --explain E0277`.","code":null,"level":"failure-note","spans":[],"children":[],"rendered":"\u001b[1mFor more information about an error, try `rustc --explain E0277`.\u001b[0m\n"}