[INFO] cloning repository https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThanhhuy2002%2FRust_bootcamp_2023_HW1", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThanhhuy2002%2FRust_bootcamp_2023_HW1'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] b33ce7e35d419f766283bdffed87a11123ded646 [INFO] checking Thanhhuy2002/Rust_bootcamp_2023_HW1 against master#74c3f5a146860c94ff4d179fc3bfa34f879adf41 for pr-120248 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThanhhuy2002%2FRust_bootcamp_2023_HW1" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 on toolchain 74c3f5a146860c94ff4d179fc3bfa34f879adf41 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+74c3f5a146860c94ff4d179fc3bfa34f879adf41" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 [INFO] removed 0 missing tests [INFO] finished tweaking git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 [INFO] tweaked toml for git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 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" "+74c3f5a146860c94ff4d179fc3bfa34f879adf41" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Blocking waiting for file lock on package cache [ERROR] error running command: no output for 300 seconds [ERROR] this task or one of its parent failed! [ERROR] no output for 300 seconds [ERROR] note: run with `RUST_BACKTRACE=1` to display a backtrace. [INFO] checking Thanhhuy2002/Rust_bootcamp_2023_HW1 against try#13cae6066db2d5e6c9bb508caceec8d34ca49980 for pr-120248 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThanhhuy2002%2FRust_bootcamp_2023_HW1" "/workspace/builds/worker-4-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc2/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 on toolchain 13cae6066db2d5e6c9bb508caceec8d34ca49980 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+13cae6066db2d5e6c9bb508caceec8d34ca49980" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 [INFO] removed 0 missing tests [INFO] finished tweaking git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 [INFO] tweaked toml for git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 written to /workspace/builds/worker-4-tc2/source/Cargo.toml [INFO] crate git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 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" "+13cae6066db2d5e6c9bb508caceec8d34ca49980" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Blocking waiting for file lock on package cache [ERROR] error running command: no output for 300 seconds [INFO] checking Thanhhuy2002/Rust_bootcamp_2023_HW1 against try#13cae6066db2d5e6c9bb508caceec8d34ca49980 for pr-120248 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FThanhhuy2002%2FRust_bootcamp_2023_HW1" "/workspace/builds/worker-4-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc2/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 on toolchain 13cae6066db2d5e6c9bb508caceec8d34ca49980 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+13cae6066db2d5e6c9bb508caceec8d34ca49980" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 [INFO] removed 0 missing tests [INFO] finished tweaking git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 [INFO] tweaked toml for git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 written to /workspace/builds/worker-4-tc2/source/Cargo.toml [INFO] crate git repo https://github.com/Thanhhuy2002/Rust_bootcamp_2023_HW1 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" "+13cae6066db2d5e6c9bb508caceec8d34ca49980" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] [stderr] Blocking waiting for file lock on package cache [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc2/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" "+13cae6066db2d5e6c9bb508caceec8d34ca49980" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 556927daf617ea84c5850f98579f5d089eb0895e86ab8a47acdeb0b11c052849 [INFO] running `Command { std: "docker" "start" "-a" "556927daf617ea84c5850f98579f5d089eb0895e86ab8a47acdeb0b11c052849", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "556927daf617ea84c5850f98579f5d089eb0895e86ab8a47acdeb0b11c052849", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "556927daf617ea84c5850f98579f5d089eb0895e86ab8a47acdeb0b11c052849", kill_on_drop: false }` [INFO] [stdout] 556927daf617ea84c5850f98579f5d089eb0895e86ab8a47acdeb0b11c052849 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc2/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "RUSTDOCFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "ghcr.io/rust-lang/crates-build-env/linux@sha256:2788e3201cd34a07e3172128adcd8b3090168a8e3bcc40d7c032b9dda1df7d1c" "/opt/rustwide/cargo-home/bin/cargo" "+13cae6066db2d5e6c9bb508caceec8d34ca49980" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 6b4e3432cd91242d09766986a60602971ceaad30df4990d551eb49c095d7a225 [INFO] running `Command { std: "docker" "start" "-a" "6b4e3432cd91242d09766986a60602971ceaad30df4990d551eb49c095d7a225", kill_on_drop: false }` [INFO] [stderr] Checking Rust-Bootcamp-2023 v0.1.0 (/opt/rustwide/workdir) [INFO] [stderr] Checking basic-of-rust v0.1.0 (/opt/rustwide/workdir/exercises/basic-of-rust) [INFO] [stdout] error: expected one of `:`, `@`, or `|`, found `,` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:3:9 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(x, y: i32) { [INFO] [stdout] | ^ expected one of `:`, `@`, or `|` [INFO] [stdout] | [INFO] [stdout] = note: anonymous parameters are removed in the 2018 edition (see RFC 1685) [INFO] [stdout] help: if this is a `self` type, give it a parameter name [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(self: x, y: i32) { [INFO] [stdout] | +++++ [INFO] [stdout] help: if this is a parameter name, give it a type [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(x: TypeName, y: i32) { [INFO] [stdout] | ++++++++++ [INFO] [stdout] help: if this is a type, explicitly ignore the parameter name [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(_: x, y: i32) { [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected one of `:`, `@`, or `|`, found `,` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:3:9 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(x, y: i32) { [INFO] [stdout] | ^ expected one of `:`, `@`, or `|` [INFO] [stdout] | [INFO] [stdout] = note: anonymous parameters are removed in the 2018 edition (see RFC 1685) [INFO] [stdout] help: if this is a `self` type, give it a parameter name [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(self: x, y: i32) { [INFO] [stdout] | +++++ [INFO] [stdout] help: if this is a parameter name, give it a type [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(x: TypeName, y: i32) { [INFO] [stdout] | ++++++++++ [INFO] [stdout] help: if this is a type, explicitly ignore the parameter name [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(_: x, y: i32) { [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: expected one of `:`, `@`, or `|`, found `,` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:3:9 [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(x, y: i32) { [INFO] [stdout] | ^ expected one of `:`, `@`, or `|` [INFO] [stdout] | [INFO] [stdout] = note: anonymous parameters are removed in the 2018 edition (see RFC 1685) [INFO] [stdout] help: if this is a `self` type, give it a parameter name [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(self: x, y: i32) { [INFO] [stdout] | +++++ [INFO] [stdout] help: if this is a parameter name, give it a type [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(x: TypeName, y: i32) { [INFO] [stdout] | ++++++++++ [INFO] [stdout] help: if this is a type, explicitly ignore the parameter name [INFO] [stdout] | [INFO] [stdout] 3 | fn sum(_: x, y: i32) { [INFO] [stdout] | ++ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: crate `Rust_Bootcamp_2023` should have a snake case name [INFO] [stdout] | [INFO] [stdout] = help: convert the identifier to snake case: `rust_bootcamp_2023` [INFO] [stdout] = note: `#[warn(non_snake_case)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 1 warning emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: crate `Rust_Bootcamp_2023` should have a snake case name [INFO] [stdout] | [INFO] [stdout] = help: convert the identifier to snake case: `rust_bootcamp_2023` [INFO] [stdout] = note: `#[warn(non_snake_case)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 1 warning emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:26:9 [INFO] [stdout] | [INFO] [stdout] 22 | pub fn foo_if_fizz(fizzish: &str) -> &str { [INFO] [stdout] | ---- expected `&str` because of return type [INFO] [stdout] ... [INFO] [stdout] 26 | 1 [INFO] [stdout] | ^ expected `&str`, found integer [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:26:9 [INFO] [stdout] | [INFO] [stdout] 22 | pub fn foo_if_fizz(fizzish: &str) -> &str { [INFO] [stdout] | ---- expected `&str` because of return type [INFO] [stdout] ... [INFO] [stdout] 26 | 1 [INFO] [stdout] | ^ expected `&str`, found integer [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:12:12 [INFO] [stdout] | [INFO] [stdout] 12 | s.push(" world"); [INFO] [stdout] | ---- ^^^^^^^^ expected `char`, found `&str` [INFO] [stdout] | | [INFO] [stdout] | arguments to this method are incorrect [INFO] [stdout] | [INFO] [stdout] note: method defined here [INFO] [stdout] --> /rustc/13cae6066db2d5e6c9bb508caceec8d34ca49980/library/alloc/src/string.rs:1344:12 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:42:23 [INFO] [stdout] | [INFO] [stdout] 42 | assert_eq!(s, 3); [INFO] [stdout] | ^ expected `()`, found integer [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0600]: cannot apply unary operator `-` to type `u32` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:77:35 [INFO] [stdout] | [INFO] [stdout] 77 | let result = check_number(-5); [INFO] [stdout] | ^^ cannot apply unary operator `-` [INFO] [stdout] | [INFO] [stdout] = note: unsigned values cannot be negated [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:12:12 [INFO] [stdout] | [INFO] [stdout] 12 | s.push(" world"); [INFO] [stdout] | ---- ^^^^^^^^ expected `char`, found `&str` [INFO] [stdout] | | [INFO] [stdout] | arguments to this method are incorrect [INFO] [stdout] | [INFO] [stdout] note: method defined here [INFO] [stdout] --> /rustc/13cae6066db2d5e6c9bb508caceec8d34ca49980/library/alloc/src/string.rs:1344:12 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:26:9 [INFO] [stdout] | [INFO] [stdout] 22 | pub fn foo_if_fizz(fizzish: &str) -> &str { [INFO] [stdout] | ---- expected `&str` because of return type [INFO] [stdout] ... [INFO] [stdout] 26 | 1 [INFO] [stdout] | ^ expected `&str`, found integer [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:6:15 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn bigger(a: i32, b: i32) -> i32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_a` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0600]: cannot apply unary operator `-` to type `u32` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:77:35 [INFO] [stdout] | [INFO] [stdout] 77 | let result = check_number(-5); [INFO] [stdout] | ^^ cannot apply unary operator `-` [INFO] [stdout] | [INFO] [stdout] = note: unsigned values cannot be negated [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `b` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:6:23 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn bigger(a: i32, b: i32) -> i32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_b` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `number` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:14:17 [INFO] [stdout] | [INFO] [stdout] 14 | fn check_number(number: u32) -> &'static str { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_number` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn sum_one_to_n(n: u32) -> u32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `year` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:33:17 [INFO] [stdout] | [INFO] [stdout] 33 | fn is_leap_year(year: i32) -> bool { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_year` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:40:14 [INFO] [stdout] | [INFO] [stdout] 40 | fn factorial(n: u32) -> u32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `numbers` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:21:22 [INFO] [stdout] | [INFO] [stdout] 21 | fn calculate_average(numbers: &[f64]) -> f64 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_numbers` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:48:13 [INFO] [stdout] | [INFO] [stdout] 48 | fn is_prime(n: u32) -> bool { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `numbers` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:27:21 [INFO] [stdout] | [INFO] [stdout] 27 | fn sum_even_numbers(numbers: &[i32]) -> i32 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_numbers` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:13:10 [INFO] [stdout] | [INFO] [stdout] 13 | s += "!".to_string(); [INFO] [stdout] | ^^^^^^^^^^^^^^^ expected `&str`, found `String` [INFO] [stdout] | [INFO] [stdout] help: try removing the method call [INFO] [stdout] | [INFO] [stdout] 13 - s += "!".to_string(); [INFO] [stdout] 13 + s += "!"; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:13:10 [INFO] [stdout] | [INFO] [stdout] 13 | s += "!".to_string(); [INFO] [stdout] | ^^^^^^^^^^^^^^^ expected `&str`, found `String` [INFO] [stdout] | [INFO] [stdout] help: try removing the method call [INFO] [stdout] | [INFO] [stdout] 13 - s += "!".to_string(); [INFO] [stdout] 13 + s += "!"; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:21:19 [INFO] [stdout] | [INFO] [stdout] 21 | let s3 = s1 + s2; [INFO] [stdout] | ^^ expected `&str`, found `String` [INFO] [stdout] | [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 21 | let s3 = s1 + &s2; [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:21:19 [INFO] [stdout] | [INFO] [stdout] 21 | let s3 = s1 + s2; [INFO] [stdout] | ^^ expected `&str`, found `String` [INFO] [stdout] | [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 21 | let s3 = s1 + &s2; [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:6:15 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn bigger(a: i32, b: i32) -> i32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_a` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `b` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:6:23 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn bigger(a: i32, b: i32) -> i32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_b` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `number` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:14:17 [INFO] [stdout] | [INFO] [stdout] 14 | fn check_number(number: u32) -> &'static str { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_number` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `year` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:33:17 [INFO] [stdout] | [INFO] [stdout] 33 | fn is_leap_year(year: i32) -> bool { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_year` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:40:14 [INFO] [stdout] | [INFO] [stdout] 40 | fn factorial(n: u32) -> u32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:48:13 [INFO] [stdout] | [INFO] [stdout] 48 | fn is_prime(n: u32) -> bool { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `color` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:3:14 [INFO] [stdout] | [INFO] [stdout] 3 | fn exercise1(color: &str) -> String { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_color` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `input` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:28:19 [INFO] [stdout] | [INFO] [stdout] 28 | fn reverse_string(input: &str) -> String { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `word` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:35:18 [INFO] [stdout] | [INFO] [stdout] 35 | fn is_palindrome(word: &str) -> bool { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_word` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `string` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:41:27 [INFO] [stdout] | [INFO] [stdout] 41 | fn count_char_occurrences(string: &str, ch: char) -> usize { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_string` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `ch` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:41:41 [INFO] [stdout] | [INFO] [stdout] 41 | fn count_char_occurrences(string: &str, ch: char) -> usize { [INFO] [stdout] | ^^ help: if this is intentional, prefix it with an underscore: `_ch` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn sum_one_to_n(n: u32) -> u32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `numbers` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:21:22 [INFO] [stdout] | [INFO] [stdout] 21 | fn calculate_average(numbers: &[f64]) -> f64 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_numbers` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `numbers` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:27:21 [INFO] [stdout] | [INFO] [stdout] 27 | fn sum_even_numbers(numbers: &[i32]) -> i32 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_numbers` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `color` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:3:14 [INFO] [stdout] | [INFO] [stdout] 3 | fn exercise1(color: &str) -> String { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_color` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:12:12 [INFO] [stdout] | [INFO] [stdout] 12 | s.push(" world"); [INFO] [stdout] | ---- ^^^^^^^^ expected `char`, found `&str` [INFO] [stdout] | | [INFO] [stdout] | arguments to this method are incorrect [INFO] [stdout] | [INFO] [stdout] note: method defined here [INFO] [stdout] --> /rustc/13cae6066db2d5e6c9bb508caceec8d34ca49980/library/alloc/src/string.rs:1344:12 [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `input` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:28:19 [INFO] [stdout] | [INFO] [stdout] 28 | fn reverse_string(input: &str) -> String { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `word` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:35:18 [INFO] [stdout] | [INFO] [stdout] 35 | fn is_palindrome(word: &str) -> bool { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_word` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `string` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:41:27 [INFO] [stdout] | [INFO] [stdout] 41 | fn count_char_occurrences(string: &str, ch: char) -> usize { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_string` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 2 previous errors; 3 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `ch` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:41:41 [INFO] [stdout] | [INFO] [stdout] 41 | fn count_char_occurrences(string: &str, ch: char) -> usize { [INFO] [stdout] | ^^ help: if this is intentional, prefix it with an underscore: `_ch` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stdout] error: aborting due to 5 previous errors; 14 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stdout] error: aborting due to 2 previous errors; 6 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0308, E0600. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:13:10 [INFO] [stdout] | [INFO] [stdout] 13 | s += "!".to_string(); [INFO] [stdout] | ^^^^^^^^^^^^^^^ expected `&str`, found `String` [INFO] [stdout] | [INFO] [stdout] help: try removing the method call [INFO] [stdout] | [INFO] [stdout] 13 - s += "!".to_string(); [INFO] [stdout] 13 + s += "!"; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `Rust-Bootcamp-2023` (test "functions") due to 3 previous errors; 3 warnings emitted [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stderr] error: could not compile `basic-of-rust` (lib) due to 6 previous errors; 14 warnings emitted [INFO] [stderr] error: could not compile `Rust-Bootcamp-2023` (test "conditions") due to 3 previous errors; 6 warnings emitted [INFO] [stdout] error: aborting due to 3 previous errors; 5 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:21:19 [INFO] [stdout] | [INFO] [stdout] 21 | let s3 = s1 + s2; [INFO] [stdout] | ^^ expected `&str`, found `String` [INFO] [stdout] | [INFO] [stdout] help: consider borrowing here [INFO] [stdout] | [INFO] [stdout] 21 | let s3 = s1 + &s2; [INFO] [stdout] | + [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] error: could not compile `Rust-Bootcamp-2023` (test "strings") due to 4 previous errors; 5 warnings emitted [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:42:23 [INFO] [stdout] | [INFO] [stdout] 42 | assert_eq!(s, 3); [INFO] [stdout] | ^ expected `()`, found integer [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:6:15 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn bigger(a: i32, b: i32) -> i32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_a` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `b` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:6:23 [INFO] [stdout] | [INFO] [stdout] 6 | pub fn bigger(a: i32, b: i32) -> i32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_b` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `number` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:14:17 [INFO] [stdout] | [INFO] [stdout] 14 | fn check_number(number: u32) -> &'static str { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_number` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `year` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:33:17 [INFO] [stdout] | [INFO] [stdout] 33 | fn is_leap_year(year: i32) -> bool { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_year` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:40:14 [INFO] [stdout] | [INFO] [stdout] 40 | fn factorial(n: u32) -> u32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/conditions.rs:48:13 [INFO] [stdout] | [INFO] [stdout] 48 | fn is_prime(n: u32) -> bool { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `color` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:3:14 [INFO] [stdout] | [INFO] [stdout] 3 | fn exercise1(color: &str) -> String { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_color` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `input` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:28:19 [INFO] [stdout] | [INFO] [stdout] 28 | fn reverse_string(input: &str) -> String { [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_input` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `word` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:35:18 [INFO] [stdout] | [INFO] [stdout] 35 | fn is_palindrome(word: &str) -> bool { [INFO] [stdout] | ^^^^ help: if this is intentional, prefix it with an underscore: `_word` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `string` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:41:27 [INFO] [stdout] | [INFO] [stdout] 41 | fn count_char_occurrences(string: &str, ch: char) -> usize { [INFO] [stdout] | ^^^^^^ help: if this is intentional, prefix it with an underscore: `_string` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `ch` [INFO] [stdout] --> exercises/basic-of-rust/src/strings.rs:41:41 [INFO] [stdout] | [INFO] [stdout] 41 | fn count_char_occurrences(string: &str, ch: char) -> usize { [INFO] [stdout] | ^^ help: if this is intentional, prefix it with an underscore: `_ch` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn sum_one_to_n(n: u32) -> u32 { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `numbers` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:21:22 [INFO] [stdout] | [INFO] [stdout] 21 | fn calculate_average(numbers: &[f64]) -> f64 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_numbers` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `numbers` [INFO] [stdout] --> exercises/basic-of-rust/src/functions.rs:27:21 [INFO] [stdout] | [INFO] [stdout] 27 | fn sum_even_numbers(numbers: &[i32]) -> i32 { [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_numbers` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 7 previous errors; 14 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0308, E0600. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stderr] error: could not compile `basic-of-rust` (lib test) due to 8 previous errors; 14 warnings emitted [INFO] running `Command { std: "docker" "inspect" "6b4e3432cd91242d09766986a60602971ceaad30df4990d551eb49c095d7a225", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "6b4e3432cd91242d09766986a60602971ceaad30df4990d551eb49c095d7a225", kill_on_drop: false }` [INFO] [stdout] 6b4e3432cd91242d09766986a60602971ceaad30df4990d551eb49c095d7a225