[INFO] cloning repository https://github.com/SynCROSS/learning-rust [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/SynCROSS/learning-rust" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FSynCROSS%2Flearning-rust", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FSynCROSS%2Flearning-rust'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 697c576775c0929c8805ae4b70fe0926d35d9929 [INFO] testing SynCROSS/learning-rust against master#a77da2d454e6caa227a85b16410b95f93495e7e0 for pr-91031 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2FSynCROSS%2Flearning-rust" "/workspace/builds/worker-58/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-58/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/SynCROSS/learning-rust on toolchain a77da2d454e6caa227a85b16410b95f93495e7e0 [INFO] running `Command { std: "/workspace/cargo-home/bin/cargo" "+a77da2d454e6caa227a85b16410b95f93495e7e0" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/SynCROSS/learning-rust [INFO] finished tweaking git repo https://github.com/SynCROSS/learning-rust [INFO] tweaked toml for git repo https://github.com/SynCROSS/learning-rust written to /workspace/builds/worker-58/source/Cargo.toml [INFO] crate git repo https://github.com/SynCROSS/learning-rust already has a lockfile, it will not be regenerated [INFO] running `Command { std: "/workspace/cargo-home/bin/cargo" "+a77da2d454e6caa227a85b16410b95f93495e7e0" "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-58/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-58/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:5736fa189c1c60b01babf4b8b698fe57b6ecc41933a7ff2e0b8d7a221459412b" "/opt/rustwide/cargo-home/bin/cargo" "+a77da2d454e6caa227a85b16410b95f93495e7e0" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 89a34541297f9af6d22d87d60d033b7edbdbb1c13942a6a07cd441e8cde04913 [INFO] running `Command { std: "docker" "start" "-a" "89a34541297f9af6d22d87d60d033b7edbdbb1c13942a6a07cd441e8cde04913", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "89a34541297f9af6d22d87d60d033b7edbdbb1c13942a6a07cd441e8cde04913", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "89a34541297f9af6d22d87d60d033b7edbdbb1c13942a6a07cd441e8cde04913", kill_on_drop: false }` [INFO] [stdout] 89a34541297f9af6d22d87d60d033b7edbdbb1c13942a6a07cd441e8cde04913 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-58/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-58/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" "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:5736fa189c1c60b01babf4b8b698fe57b6ecc41933a7ff2e0b8d7a221459412b" "/opt/rustwide/cargo-home/bin/cargo" "+a77da2d454e6caa227a85b16410b95f93495e7e0" "build" "--frozen" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 6f1ab229f0de32279f4d45a494383fbad1293d6a08d6694fb278ede502d22acc [INFO] running `Command { std: "docker" "start" "-a" "6f1ab229f0de32279f4d45a494383fbad1293d6a08d6694fb278ede502d22acc", kill_on_drop: false }` [INFO] [stderr] Compiling rand_core v0.4.2 [INFO] [stderr] Compiling autocfg v0.1.7 [INFO] [stderr] Compiling libc v0.2.86 [INFO] [stderr] Compiling rand_core v0.3.1 [INFO] [stderr] Compiling rand_jitter v0.1.4 [INFO] [stderr] Compiling rand_isaac v0.1.1 [INFO] [stderr] Compiling rand_xorshift v0.1.1 [INFO] [stderr] Compiling rand_hc v0.1.0 [INFO] [stderr] Compiling rand_chacha v0.1.1 [INFO] [stderr] Compiling rand_pcg v0.1.2 [INFO] [stderr] Compiling rand v0.6.5 [INFO] [stderr] Compiling rand_os v0.1.3 [INFO] [stderr] Compiling learning-rust v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] error[E0308]: `if` and `else` have incompatible types [INFO] [stdout] --> src/lib.rs:46:9 [INFO] [stdout] | [INFO] [stdout] 36 | / if switch { [INFO] [stdout] 37 | | NewsArticle { [INFO] [stdout] | _|_________- [INFO] [stdout] 38 | | | headline: String::from("Penguins win the Stanley Cup Championship!"), [INFO] [stdout] 39 | | | location: String::from("Pittsburgh, PA, USA"), [INFO] [stdout] 40 | | | author: String::from("Iceburgh"), [INFO] [stdout] ... | | [INFO] [stdout] 43 | | | ), [INFO] [stdout] 44 | | | } [INFO] [stdout] | |_|_________- expected because of this [INFO] [stdout] 45 | | } else { [INFO] [stdout] 46 | / | Tweet { [INFO] [stdout] 47 | | | username: String::from("horse_ebooks"), [INFO] [stdout] 48 | | | content: String::from("of course, as you probably already know, people"), [INFO] [stdout] 49 | | | reply: false, [INFO] [stdout] 50 | | | retweet: false, [INFO] [stdout] 51 | | | } [INFO] [stdout] | |_|_________^ expected struct `NewsArticle`, found struct `Tweet` [INFO] [stdout] 52 | | } [INFO] [stdout] | |_____- `if` and `else` have incompatible types [INFO] [stdout] | [INFO] [stdout] help: you could change the return type to be a boxed trait object [INFO] [stdout] | [INFO] [stdout] 35 | fn returns_summarizable(switch: bool) -> Box { [INFO] [stdout] | ~~~~~~~ + [INFO] [stdout] help: if you change the return type to expect trait objects, box the returned expressions [INFO] [stdout] | [INFO] [stdout] 37 ~ Box::new(NewsArticle { [INFO] [stdout] 38 | headline: String::from("Penguins win the Stanley Cup Championship!"), [INFO] [stdout] 39 | location: String::from("Pittsburgh, PA, USA"), [INFO] [stdout] 40 | author: String::from("Iceburgh"), [INFO] [stdout] 41 | content: String::from( [INFO] [stdout] 42 | "The Pittsburgh Penguins once again are the best hockey team in the NHL.", [INFO] [stdout] ... [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to previous error [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] For more information about this error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stderr] error: could not compile `learning-rust` due to 2 previous errors [INFO] [stderr] warning: build failed, waiting for other jobs to finish... [INFO] [stderr] error: build failed [INFO] running `Command { std: "docker" "inspect" "6f1ab229f0de32279f4d45a494383fbad1293d6a08d6694fb278ede502d22acc", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "6f1ab229f0de32279f4d45a494383fbad1293d6a08d6694fb278ede502d22acc", kill_on_drop: false }` [INFO] [stdout] 6f1ab229f0de32279f4d45a494383fbad1293d6a08d6694fb278ede502d22acc