[INFO] cloning repository https://github.com/masa-matt/rust-tutrial [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/masa-matt/rust-tutrial" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fmasa-matt%2Frust-tutrial", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fmasa-matt%2Frust-tutrial'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] f572f11c89d483c1e75e90de7350b967c35b7b45 [INFO] checking masa-matt/rust-tutrial against master#af4a5a13a15fa0c60e06321077ef452f769b42fd for pr-122960-4 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fmasa-matt%2Frust-tutrial" "/workspace/builds/worker-0-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-0-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/masa-matt/rust-tutrial on toolchain af4a5a13a15fa0c60e06321077ef452f769b42fd [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/masa-matt/rust-tutrial [INFO] finished tweaking git repo https://github.com/masa-matt/rust-tutrial [INFO] tweaked toml for git repo https://github.com/masa-matt/rust-tutrial written to /workspace/builds/worker-0-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/masa-matt/rust-tutrial already has a lockfile, it will not be regenerated [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] warning: virtual workspace defaulting to `resolver = "1"` despite one or more workspace members being on edition 2021 which implies `resolver = "2"` [INFO] [stderr] note: to keep the current resolver, specify `workspace.resolver = "1"` in the workspace root's manifest [INFO] [stderr] note: to use the edition 2021 resolver, specify `workspace.resolver = "2"` in the workspace root's manifest [INFO] [stderr] note: for more details see https://doc.rust-lang.org/cargo/reference/resolver.html#resolver-versions [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Updating crates.io index [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded rug v1.19.0 [INFO] [stderr] Downloaded gmp-mpfr-sys v1.5.0 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:2788e3201cd34a07e3172128adcd8b3090168a8e3bcc40d7c032b9dda1df7d1c" "/opt/rustwide/cargo-home/bin/cargo" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 7a687dde0d40a3e701800acd6a6a6663494268f5c9da5d92984aa501c61a4dca [INFO] running `Command { std: "docker" "start" "-a" "7a687dde0d40a3e701800acd6a6a6663494268f5c9da5d92984aa501c61a4dca", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "7a687dde0d40a3e701800acd6a6a6663494268f5c9da5d92984aa501c61a4dca", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "7a687dde0d40a3e701800acd6a6a6663494268f5c9da5d92984aa501c61a4dca", kill_on_drop: false }` [INFO] [stdout] 7a687dde0d40a3e701800acd6a6a6663494268f5c9da5d92984aa501c61a4dca [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-0-tc1/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=allow" "-e" "RUSTDOCFLAGS=--cap-lints=allow" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:2788e3201cd34a07e3172128adcd8b3090168a8e3bcc40d7c032b9dda1df7d1c" "/opt/rustwide/cargo-home/bin/cargo" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] a826ca85b091e558e6eee731dd3f3b3cdb8350cbdad841ed678cb54b705e2233 [INFO] running `Command { std: "docker" "start" "-a" "a826ca85b091e558e6eee731dd3f3b3cdb8350cbdad841ed678cb54b705e2233", kill_on_drop: false }` [INFO] [stderr] warning: virtual workspace defaulting to `resolver = "1"` despite one or more workspace members being on edition 2021 which implies `resolver = "2"` [INFO] [stderr] note: to keep the current resolver, specify `workspace.resolver = "1"` in the workspace root's manifest [INFO] [stderr] note: to use the edition 2021 resolver, specify `workspace.resolver = "2"` in the workspace root's manifest [INFO] [stderr] note: for more details see https://doc.rust-lang.org/cargo/reference/resolver.html#resolver-versions [INFO] [stderr] Compiling libc v0.2.139 [INFO] [stderr] Compiling gmp-mpfr-sys v1.5.0 [INFO] [stderr] Compiling rug v1.19.0 [INFO] [stderr] Checking ch11-03-test-organization v0.1.0 (/opt/rustwide/workdir/ch11/ch11-03-test-organization) [INFO] [stderr] Checking ch07-04-bringing-paths-into-scope-with-the-use-keyword v0.1.0 (/opt/rustwide/workdir/ch07/ch07-04-bringing-paths-into-scope-with-the-use-keyword) [INFO] [stderr] Checking ch05-01-defining-structs v0.1.0 (/opt/rustwide/workdir/ch05/ch05-01-defining-structs) [INFO] [stderr] Checking variables v0.1.0 (/opt/rustwide/workdir/ch03/ch03-01-variables-and-mutability) [INFO] [stderr] Checking ch04-02-references-and-borrowing v0.1.0 (/opt/rustwide/workdir/ch04/ch04-02-references-and-borrowing) [INFO] [stderr] Checking ch10-02-traits v0.1.0 (/opt/rustwide/workdir/ch10/ch10-02-traits) [INFO] [stderr] Checking ch09-02-recoverable-errors-with-result v0.1.0 (/opt/rustwide/workdir/ch09/ch09-02-recoverable-errors-with-result) [INFO] [stderr] Checking ch03-04-comments v0.1.0 (/opt/rustwide/workdir/ch03/ch03-04-comments) [INFO] [stderr] Checking ch09-03-to-panic-or-not-to-panic v0.1.0 (/opt/rustwide/workdir/ch09/ch09-03-to-panic-or-not-to-panic) [INFO] [stderr] Checking ch10-03-lifetime-syntax v0.1.0 (/opt/rustwide/workdir/ch10/ch10-03-lifetime-syntax) [INFO] [stderr] Checking ch10-00-generics v0.1.0 (/opt/rustwide/workdir/ch10/ch10-00-generics) [INFO] [stderr] Checking ch05-02-example-structs v0.1.0 (/opt/rustwide/workdir/ch05/ch05-02-example-structs) [INFO] [stdout] error[E0252]: the name `io` is defined multiple times [INFO] [stdout] --> ch07/ch07-04-bringing-paths-into-scope-with-the-use-keyword/src/lib.rs:68:26 [INFO] [stdout] | [INFO] [stdout] 43 | use std::io; [INFO] [stdout] | ------- previous import of the module `io` here [INFO] [stdout] ... [INFO] [stdout] 68 | use std::{cmp::Ordering, io}; [INFO] [stdout] | ^^ `io` reimported here [INFO] [stdout] | [INFO] [stdout] = note: `io` must be defined only once in the type namespace of this module [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0252]: the name `io` is defined multiple times [INFO] [stdout] --> ch07/ch07-04-bringing-paths-into-scope-with-the-use-keyword/src/lib.rs:73:15 [INFO] [stdout] | [INFO] [stdout] 43 | use std::io; [INFO] [stdout] | ------- previous import of the module `io` here [INFO] [stdout] ... [INFO] [stdout] 73 | use std::io::{self, Write}; [INFO] [stdout] | ^^^^-- [INFO] [stdout] | | [INFO] [stdout] | `io` reimported here [INFO] [stdout] | help: remove unnecessary import [INFO] [stdout] | [INFO] [stdout] = note: `io` must be defined only once in the type namespace of this module [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Checking ch06-02-match v0.1.0 (/opt/rustwide/workdir/ch06/ch06-02-match) [INFO] [stdout] error: aborting due to 2 previous errors [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0252`. [INFO] [stdout] [INFO] [stderr] error: could not compile `ch07-04-bringing-paths-into-scope-with-the-use-keyword` (lib test) due to 3 previous errors [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stdout] error[E0432]: unresolved import `rand` [INFO] [stdout] --> ch09/ch09-03-to-panic-or-not-to-panic/src/main.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use rand::Rng; [INFO] [stdout] | ^^^^ use of undeclared crate or module `rand` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0106]: missing lifetime specifier [INFO] [stdout] --> ch04/ch04-02-references-and-borrowing/src/main.rs:68:16 [INFO] [stdout] | [INFO] [stdout] 68 | fn dangle() -> &String { [INFO] [stdout] | ^ expected named lifetime parameter [INFO] [stdout] | [INFO] [stdout] = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from [INFO] [stdout] help: consider using the `'static` lifetime, but this is uncommon unless you're returning a borrowed value from a `const` or a `static` [INFO] [stdout] | [INFO] [stdout] 68 | fn dangle() -> &'static String { [INFO] [stdout] | +++++++ [INFO] [stdout] help: instead, you are more likely to want to return an owned value [INFO] [stdout] | [INFO] [stdout] 68 - fn dangle() -> &String { [INFO] [stdout] 68 + fn dangle() -> String { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0515]: cannot return reference to local variable `s` [INFO] [stdout] --> ch04/ch04-02-references-and-borrowing/src/main.rs:73:5 [INFO] [stdout] | [INFO] [stdout] 73 | &s // we return a reference to the String, s [INFO] [stdout] | ^^ returns a reference to data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0433]: failed to resolve: use of undeclared crate or module `rand` [INFO] [stdout] --> ch09/ch09-03-to-panic-or-not-to-panic/src/main.rs:38:25 [INFO] [stdout] | [INFO] [stdout] 38 | let secret_number = rand::thread_rng().gen_range(1..=100); [INFO] [stdout] | ^^^^ use of undeclared crate or module `rand` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 2 previous errors [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0106, E0515. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0106`. [INFO] [stdout] [INFO] [stderr] error: could not compile `ch04-02-references-and-borrowing` (bin "ch04-02-references-and-borrowing" test) due to 3 previous errors [INFO] [stdout] error: aborting due to 2 previous errors [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0432, E0433. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0432`. [INFO] [stdout] [INFO] [stdout] error[E0106]: missing lifetime specifier [INFO] [stdout] --> ch04/ch04-02-references-and-borrowing/src/main.rs:68:16 [INFO] [stdout] | [INFO] [stdout] 68 | fn dangle() -> &String { [INFO] [stdout] | ^ expected named lifetime parameter [INFO] [stdout] | [INFO] [stdout] = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from [INFO] [stdout] help: consider using the `'static` lifetime, but this is uncommon unless you're returning a borrowed value from a `const` or a `static` [INFO] [stdout] | [INFO] [stdout] 68 | fn dangle() -> &'static String { [INFO] [stdout] | +++++++ [INFO] [stdout] help: instead, you are more likely to want to return an owned value [INFO] [stdout] | [INFO] [stdout] 68 - fn dangle() -> &String { [INFO] [stdout] 68 + fn dangle() -> String { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `ch09-03-to-panic-or-not-to-panic` (bin "ch09-03-to-panic-or-not-to-panic" test) due to 3 previous errors [INFO] [stdout] error[E0515]: cannot return reference to local variable `s` [INFO] [stdout] --> ch04/ch04-02-references-and-borrowing/src/main.rs:73:5 [INFO] [stdout] | [INFO] [stdout] 73 | &s // we return a reference to the String, s [INFO] [stdout] | ^^ returns a reference to data owned by the current function [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 2 previous errors [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0106, E0515. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0106`. [INFO] [stdout] [INFO] [stderr] error: could not compile `ch04-02-references-and-borrowing` (bin "ch04-02-references-and-borrowing") due to 3 previous errors [INFO] running `Command { std: "docker" "inspect" "a826ca85b091e558e6eee731dd3f3b3cdb8350cbdad841ed678cb54b705e2233", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "a826ca85b091e558e6eee731dd3f3b3cdb8350cbdad841ed678cb54b705e2233", kill_on_drop: false }` [INFO] [stdout] a826ca85b091e558e6eee731dd3f3b3cdb8350cbdad841ed678cb54b705e2233