[INFO] cloning repository https://github.com/koonopek/crypto-pals-rust [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/koonopek/crypto-pals-rust" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fkoonopek%2Fcrypto-pals-rust", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fkoonopek%2Fcrypto-pals-rust'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 04f52464b52c708498eb237208d37259fd9ec9aa [INFO] checking koonopek/crypto-pals-rust against master#af4a5a13a15fa0c60e06321077ef452f769b42fd for pr-122960-3 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fkoonopek%2Fcrypto-pals-rust" "/workspace/builds/worker-2-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-2-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/koonopek/crypto-pals-rust 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/koonopek/crypto-pals-rust [INFO] finished tweaking git repo https://github.com/koonopek/crypto-pals-rust [INFO] tweaked toml for git repo https://github.com/koonopek/crypto-pals-rust written to /workspace/builds/worker-2-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/koonopek/crypto-pals-rust 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] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-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] bafc6fbc63d9cad4a8d9ad21123e0d34b9cd820292334081b43b66045c9762d2 [INFO] running `Command { std: "docker" "start" "-a" "bafc6fbc63d9cad4a8d9ad21123e0d34b9cd820292334081b43b66045c9762d2", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "bafc6fbc63d9cad4a8d9ad21123e0d34b9cd820292334081b43b66045c9762d2", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "bafc6fbc63d9cad4a8d9ad21123e0d34b9cd820292334081b43b66045c9762d2", kill_on_drop: false }` [INFO] [stdout] bafc6fbc63d9cad4a8d9ad21123e0d34b9cd820292334081b43b66045c9762d2 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-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=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" "+af4a5a13a15fa0c60e06321077ef452f769b42fd" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 97896d436a9e25a90916c25eebcae341222deafcc7cdfc88f1a29e51722c4824 [INFO] running `Command { std: "docker" "start" "-a" "97896d436a9e25a90916c25eebcae341222deafcc7cdfc88f1a29e51722c4824", kill_on_drop: false }` [INFO] [stderr] Checking crypto-pals v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unused import: `std::borrow::Borrow` [INFO] [stdout] --> src/bytes.rs:1:5 [INFO] [stdout] | [INFO] [stdout] 1 | use std::borrow::Borrow; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `decode_hex`, `str_to_bytes` [INFO] [stdout] --> src/xor_cipher.rs:8:34 [INFO] [stdout] | [INFO] [stdout] 8 | use crate::bytes::{bytes_to_str, decode_hex, str_to_bytes, Bytes}; [INFO] [stdout] | ^^^^^^^^^^ ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `enc_letter` [INFO] [stdout] --> src/xor_cipher.rs:122:15 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_enc_letter` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> src/xor_cipher.rs:122:27 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `Bytes` is never used [INFO] [stdout] --> src/bytes.rs:3:10 [INFO] [stdout] | [INFO] [stdout] 3 | pub type Bytes = Vec; [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `BASE64_CHARS` is never used [INFO] [stdout] --> src/bytes.rs:5:7 [INFO] [stdout] | [INFO] [stdout] 5 | const BASE64_CHARS: [u8; 63] = [ [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_a` is never used [INFO] [stdout] --> src/bytes.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | const ASCII_a: u8 = 97; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_f` is never used [INFO] [stdout] --> src/bytes.rs:12:7 [INFO] [stdout] | [INFO] [stdout] 12 | const ASCII_f: u8 = 102; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_0` is never used [INFO] [stdout] --> src/bytes.rs:14:7 [INFO] [stdout] | [INFO] [stdout] 14 | const ASCII_0: u8 = 48; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_9` is never used [INFO] [stdout] --> src/bytes.rs:15:7 [INFO] [stdout] | [INFO] [stdout] 15 | const ASCII_9: u8 = 57; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `str_to_bytes` is never used [INFO] [stdout] --> src/bytes.rs:17:8 [INFO] [stdout] | [INFO] [stdout] 17 | pub fn str_to_bytes(str: String) -> Bytes { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bytes_to_str` is never used [INFO] [stdout] --> src/bytes.rs:21:8 [INFO] [stdout] | [INFO] [stdout] 21 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bytes3_to_base64` is never used [INFO] [stdout] --> src/bytes.rs:26:4 [INFO] [stdout] | [INFO] [stdout] 26 | fn bytes3_to_base64(a: &u8, b: &u8, c: &u8) -> [u8; 4] { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hex_to_base64` is never used [INFO] [stdout] --> src/bytes.rs:42:4 [INFO] [stdout] | [INFO] [stdout] 42 | fn hex_to_base64(hex: &Bytes) -> Bytes { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `decode_hex` is never used [INFO] [stdout] --> src/bytes.rs:58:8 [INFO] [stdout] | [INFO] [stdout] 58 | pub fn decode_hex(bytes: Bytes) -> Bytes { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ENG_FREQ_CHARS` is never used [INFO] [stdout] --> src/xor_cipher.rs:10:7 [INFO] [stdout] | [INFO] [stdout] 10 | const ENG_FREQ_CHARS: [u8; 6] = [101, 116, 97, 105, 111, 110]; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ENG_FREQ_CHARS_WITH_SCORE` is never used [INFO] [stdout] --> src/xor_cipher.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | const ENG_FREQ_CHARS_WITH_SCORE: [(u8, u8); 6] = [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `xor` is never used [INFO] [stdout] --> src/xor_cipher.rs:14:4 [INFO] [stdout] | [INFO] [stdout] 14 | fn xor(a: &Bytes, b: &Bytes) -> Bytes { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hist_bytes` is never used [INFO] [stdout] --> src/xor_cipher.rs:21:4 [INFO] [stdout] | [INFO] [stdout] 21 | fn hist_bytes(bytes: &Bytes) -> HashMap { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_possible_keys` is never used [INFO] [stdout] --> src/xor_cipher.rs:55:4 [INFO] [stdout] | [INFO] [stdout] 55 | fn get_possible_keys(letters: Vec, hist_bytes: &HashMap, n: u8) -> Vec<(u8, u8, u64)> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `score_english_text` is never used [INFO] [stdout] --> src/xor_cipher.rs:96:4 [INFO] [stdout] | [INFO] [stdout] 96 | fn score_english_text(text: &Bytes) -> i64 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `decrypt_xor_by_freq_letters` is never used [INFO] [stdout] --> src/xor_cipher.rs:118:4 [INFO] [stdout] | [INFO] [stdout] 118 | fn decrypt_xor_by_freq_letters(cipher_text: &Bytes) -> (String, i64) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_lines` is never used [INFO] [stdout] --> src/xor_cipher.rs:135:4 [INFO] [stdout] | [INFO] [stdout] 135 | fn read_lines

(filename: P) -> io::Result>> [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_a` should have an upper case name [INFO] [stdout] --> src/bytes.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | const ASCII_a: u8 = 97; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to upper case: `ASCII_A` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_upper_case_globals)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_f` should have an upper case name [INFO] [stdout] --> src/bytes.rs:12:7 [INFO] [stdout] | [INFO] [stdout] 12 | const ASCII_f: u8 = 102; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to upper case (notice the capitalization): `ASCII_F` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 25 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `enc_letter` [INFO] [stdout] --> src/xor_cipher.rs:122:15 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_enc_letter` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> src/xor_cipher.rs:122:27 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_a` should have an upper case name [INFO] [stdout] --> src/bytes.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | const ASCII_a: u8 = 97; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to upper case: `ASCII_A` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_upper_case_globals)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_f` should have an upper case name [INFO] [stdout] --> src/bytes.rs:12:7 [INFO] [stdout] | [INFO] [stdout] 12 | const ASCII_f: u8 = 102; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to upper case (notice the capitalization): `ASCII_F` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 4 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.11s [INFO] running `Command { std: "docker" "inspect" "97896d436a9e25a90916c25eebcae341222deafcc7cdfc88f1a29e51722c4824", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "97896d436a9e25a90916c25eebcae341222deafcc7cdfc88f1a29e51722c4824", kill_on_drop: false }` [INFO] [stdout] 97896d436a9e25a90916c25eebcae341222deafcc7cdfc88f1a29e51722c4824 [INFO] checking koonopek/crypto-pals-rust against try#36dbcaee1a55543dfc181be52a69d99ff46ff62f for pr-122960-3 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fkoonopek%2Fcrypto-pals-rust" "/workspace/builds/worker-2-tc2/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-2-tc2/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/koonopek/crypto-pals-rust on toolchain 36dbcaee1a55543dfc181be52a69d99ff46ff62f [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/koonopek/crypto-pals-rust [INFO] finished tweaking git repo https://github.com/koonopek/crypto-pals-rust [INFO] tweaked toml for git repo https://github.com/koonopek/crypto-pals-rust written to /workspace/builds/worker-2-tc2/source/Cargo.toml [INFO] crate git repo https://github.com/koonopek/crypto-pals-rust 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" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-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" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 2993d1f84b48ea7d9ffbdbd41a494f12afcfa880e2a28c2950a81c177f9044e7 [INFO] running `Command { std: "docker" "start" "-a" "2993d1f84b48ea7d9ffbdbd41a494f12afcfa880e2a28c2950a81c177f9044e7", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "2993d1f84b48ea7d9ffbdbd41a494f12afcfa880e2a28c2950a81c177f9044e7", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "2993d1f84b48ea7d9ffbdbd41a494f12afcfa880e2a28c2950a81c177f9044e7", kill_on_drop: false }` [INFO] [stdout] 2993d1f84b48ea7d9ffbdbd41a494f12afcfa880e2a28c2950a81c177f9044e7 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-tc2/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-2-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" "+36dbcaee1a55543dfc181be52a69d99ff46ff62f" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 1623c794f3cbf2f29dbbdf4b9a3bdcf7635783addc25e837c6635c22cdc2bd35 [INFO] running `Command { std: "docker" "start" "-a" "1623c794f3cbf2f29dbbdf4b9a3bdcf7635783addc25e837c6635c22cdc2bd35", kill_on_drop: false }` [INFO] [stderr] Copying to /tmp/fixit [INFO] [stderr] Running `cargo fix --edition` [INFO] [stderr] Checking crypto-pals v0.1.0 (/tmp/fixit) [INFO] [stderr] Migrating src/main.rs from 2021 edition to 2024 [INFO] [stderr] Fixed src/bytes.rs (1 fix) [INFO] [stderr] Fixed src/xor_cipher.rs (1 fix) [INFO] [stdout] warning: unused variable: `enc_letter` [INFO] [stdout] --> src/xor_cipher.rs:122:15 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_enc_letter` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> src/xor_cipher.rs:122:27 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: type alias `Bytes` is never used [INFO] [stdout] --> src/bytes.rs:2:10 [INFO] [stdout] | [INFO] [stdout] 2 | pub type Bytes = Vec; [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(dead_code)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `BASE64_CHARS` is never used [INFO] [stdout] --> src/bytes.rs:4:7 [INFO] [stdout] | [INFO] [stdout] 4 | const BASE64_CHARS: [u8; 63] = [ [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_a` is never used [INFO] [stdout] --> src/bytes.rs:10:7 [INFO] [stdout] | [INFO] [stdout] 10 | const ASCII_a: u8 = 97; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_f` is never used [INFO] [stdout] --> src/bytes.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | const ASCII_f: u8 = 102; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_0` is never used [INFO] [stdout] --> src/bytes.rs:13:7 [INFO] [stdout] | [INFO] [stdout] 13 | const ASCII_0: u8 = 48; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_9` is never used [INFO] [stdout] --> src/bytes.rs:14:7 [INFO] [stdout] | [INFO] [stdout] 14 | const ASCII_9: u8 = 57; [INFO] [stdout] | ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `str_to_bytes` is never used [INFO] [stdout] --> src/bytes.rs:16:8 [INFO] [stdout] | [INFO] [stdout] 16 | pub fn str_to_bytes(str: String) -> Bytes { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bytes_to_str` is never used [INFO] [stdout] --> src/bytes.rs:20:8 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `bytes3_to_base64` is never used [INFO] [stdout] --> src/bytes.rs:25:4 [INFO] [stdout] | [INFO] [stdout] 25 | fn bytes3_to_base64(a: &u8, b: &u8, c: &u8) -> [u8; 4] { [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hex_to_base64` is never used [INFO] [stdout] --> src/bytes.rs:41:4 [INFO] [stdout] | [INFO] [stdout] 41 | fn hex_to_base64(hex: &Bytes) -> Bytes { [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `decode_hex` is never used [INFO] [stdout] --> src/bytes.rs:57:8 [INFO] [stdout] | [INFO] [stdout] 57 | pub fn decode_hex(bytes: Bytes) -> Bytes { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ENG_FREQ_CHARS` is never used [INFO] [stdout] --> src/xor_cipher.rs:10:7 [INFO] [stdout] | [INFO] [stdout] 10 | const ENG_FREQ_CHARS: [u8; 6] = [101, 116, 97, 105, 111, 110]; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ENG_FREQ_CHARS_WITH_SCORE` is never used [INFO] [stdout] --> src/xor_cipher.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | const ENG_FREQ_CHARS_WITH_SCORE: [(u8, u8); 6] = [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `xor` is never used [INFO] [stdout] --> src/xor_cipher.rs:14:4 [INFO] [stdout] | [INFO] [stdout] 14 | fn xor(a: &Bytes, b: &Bytes) -> Bytes { [INFO] [stdout] | ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `hist_bytes` is never used [INFO] [stdout] --> src/xor_cipher.rs:21:4 [INFO] [stdout] | [INFO] [stdout] 21 | fn hist_bytes(bytes: &Bytes) -> HashMap { [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `get_possible_keys` is never used [INFO] [stdout] --> src/xor_cipher.rs:55:4 [INFO] [stdout] | [INFO] [stdout] 55 | fn get_possible_keys(letters: Vec, hist_bytes: &HashMap, n: u8) -> Vec<(u8, u8, u64)> { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `score_english_text` is never used [INFO] [stdout] --> src/xor_cipher.rs:96:4 [INFO] [stdout] | [INFO] [stdout] 96 | fn score_english_text(text: &Bytes) -> i64 { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `decrypt_xor_by_freq_letters` is never used [INFO] [stdout] --> src/xor_cipher.rs:118:4 [INFO] [stdout] | [INFO] [stdout] 118 | fn decrypt_xor_by_freq_letters(cipher_text: &Bytes) -> (String, i64) { [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `read_lines` is never used [INFO] [stdout] --> src/xor_cipher.rs:135:4 [INFO] [stdout] | [INFO] [stdout] 135 | fn read_lines

(filename: P) -> io::Result>> [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_a` should have an upper case name [INFO] [stdout] --> src/bytes.rs:10:7 [INFO] [stdout] | [INFO] [stdout] 10 | const ASCII_a: u8 = 97; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to upper case: `ASCII_A` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_upper_case_globals)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: constant `ASCII_f` should have an upper case name [INFO] [stdout] --> src/bytes.rs:11:7 [INFO] [stdout] | [INFO] [stdout] 11 | const ASCII_f: u8 = 102; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to upper case (notice the capitalization): `ASCII_F` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: 23 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `decode_hex` in this scope [INFO] [stdout] --> src/xor_cipher.rs:32:17 [INFO] [stdout] | [INFO] [stdout] 32 | let input = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^ not found in this scope [INFO] [stdout] | [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::decode_hex; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:32:28 [INFO] [stdout] | [INFO] [stdout] 32 | let input = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 32 | let input = decode_hex(bytes_to_str(String::from( [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `decode_hex` in this scope [INFO] [stdout] --> src/xor_cipher.rs:35:15 [INFO] [stdout] | [INFO] [stdout] 35 | let key = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^ not found in this scope [INFO] [stdout] | [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::decode_hex; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:35:26 [INFO] [stdout] | [INFO] [stdout] 35 | let key = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 35 | let key = decode_hex(bytes_to_str(String::from( [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `decode_hex` in this scope [INFO] [stdout] --> src/xor_cipher.rs:38:20 [INFO] [stdout] | [INFO] [stdout] 38 | let expected = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^ not found in this scope [INFO] [stdout] | [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::decode_hex; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:38:31 [INFO] [stdout] | [INFO] [stdout] 38 | let expected = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 38 | let expected = decode_hex(bytes_to_str(String::from( [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:112:36 [INFO] [stdout] | [INFO] [stdout] 112 | assert_eq!(score_english_text(&str_to_bytes(String::from("ee"))), 24); [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 112 | assert_eq!(score_english_text(&bytes_to_str(String::from("ee"))), 24); [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:113:36 [INFO] [stdout] | [INFO] [stdout] 113 | assert_eq!(score_english_text(&str_to_bytes(String::from("0"))), -10); [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 113 | assert_eq!(score_english_text(&bytes_to_str(String::from("0"))), -10); [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:114:36 [INFO] [stdout] | [INFO] [stdout] 114 | assert_eq!(score_english_text(&str_to_bytes(String::from("0e"))), 2); [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 114 | assert_eq!(score_english_text(&bytes_to_str(String::from("0e"))), 2); [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:115:36 [INFO] [stdout] | [INFO] [stdout] 115 | assert_eq!(score_english_text(&str_to_bytes(String::from("0eo"))), 8); [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 115 | assert_eq!(score_english_text(&bytes_to_str(String::from("0eo"))), 8); [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `decode_hex` in this scope [INFO] [stdout] --> src/xor_cipher.rs:145:23 [INFO] [stdout] | [INFO] [stdout] 145 | let cipher_text = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^ not found in this scope [INFO] [stdout] | [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::decode_hex; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:145:34 [INFO] [stdout] | [INFO] [stdout] 145 | let cipher_text = decode_hex(str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 145 | let cipher_text = decode_hex(bytes_to_str(String::from( [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `decode_hex` in this scope [INFO] [stdout] --> src/xor_cipher.rs:162:54 [INFO] [stdout] | [INFO] [stdout] 162 | let decrypted = decrypt_xor_by_freq_letters(&decode_hex(str_to_bytes(cipher.unwrap()))); [INFO] [stdout] | ^^^^^^^^^^ not found in this scope [INFO] [stdout] | [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::decode_hex; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:162:65 [INFO] [stdout] | [INFO] [stdout] 162 | let decrypted = decrypt_xor_by_freq_letters(&decode_hex(str_to_bytes(cipher.unwrap()))); [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 162 | let decrypted = decrypt_xor_by_freq_letters(&decode_hex(bytes_to_str(cipher.unwrap()))); [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:175:17 [INFO] [stdout] | [INFO] [stdout] 175 | let input = str_to_bytes(String::from( [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 175 | let input = bytes_to_str(String::from( [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `decode_hex` in this scope [INFO] [stdout] --> src/xor_cipher.rs:179:20 [INFO] [stdout] | [INFO] [stdout] 179 | let expected = decode_hex(str_to_bytes(String::from("0b3637272a2b2e63622c2e69692a23693a2a3c6324202d623d63343c2a26226324272765272a282b... [INFO] [stdout] | ^^^^^^^^^^ not found in this scope [INFO] [stdout] | [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::decode_hex; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:179:31 [INFO] [stdout] | [INFO] [stdout] 179 | let expected = decode_hex(str_to_bytes(String::from("0b3637272a2b2e63622c2e69692a23693a2a3c6324202d623d63343c2a26226324272765272a282b... [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 179 | let expected = decode_hex(bytes_to_str(String::from("0b3637272a2b2e63622c2e69692a23693a2a3c6324202d623d63343c2a26226324272765272a282b2f20430a652e2c652a3124333a653e2b2027630c692b20283165286326302e27282f"))); [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0425]: cannot find function `str_to_bytes` in this scope [INFO] [stdout] --> src/xor_cipher.rs:181:34 [INFO] [stdout] | [INFO] [stdout] 181 | let encrypted = xor(&input, &str_to_bytes(String::from("ICE"))); [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] ::: src/bytes.rs:20:1 [INFO] [stdout] | [INFO] [stdout] 20 | pub fn bytes_to_str(bytes: &Bytes) -> String { [INFO] [stdout] | -------------------------------------------- similarly named function `bytes_to_str` defined here [INFO] [stdout] | [INFO] [stdout] help: a function with a similar name exists [INFO] [stdout] | [INFO] [stdout] 181 | let encrypted = xor(&input, &bytes_to_str(String::from("ICE"))); [INFO] [stdout] | ~~~~~~~~~~~~ [INFO] [stdout] help: consider importing this function [INFO] [stdout] | [INFO] [stdout] 1 + use crate::bytes::str_to_bytes; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0599]: no method named `borrow` found for struct `Vec` in the current scope [INFO] [stdout] --> src/bytes.rs:88:36 [INFO] [stdout] | [INFO] [stdout] 88 | assert_eq!(hex_to_base64(input.borrow()).len(), expected.len()); [INFO] [stdout] | ^^^^^^ [INFO] [stdout] --> /rustc/36dbcaee1a55543dfc181be52a69d99ff46ff62f/library/core/src/borrow.rs:178:8 [INFO] [stdout] | [INFO] [stdout] = note: the method is available for `Vec` here [INFO] [stdout] | [INFO] [stdout] = help: items from traits can only be used if the trait is in scope [INFO] [stdout] help: trait `Borrow` which provides `borrow` is implemented but not in scope; perhaps you want to import it [INFO] [stdout] | [INFO] [stdout] 2 + use std::borrow::Borrow; [INFO] [stdout] | [INFO] [stdout] help: there is a method `borrow_mut` with a similar name [INFO] [stdout] | [INFO] [stdout] 88 | assert_eq!(hex_to_base64(input.borrow_mut()).len(), expected.len()); [INFO] [stdout] | ~~~~~~~~~~ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `enc_letter` [INFO] [stdout] --> src/xor_cipher.rs:122:15 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_enc_letter` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> src/xor_cipher.rs:122:27 [INFO] [stdout] | [INFO] [stdout] 122 | for (key, enc_letter, n) in keys { [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error: aborting due to 19 previous errors; 2 warnings emitted [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0425, E0599. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0425`. [INFO] [stdout] [INFO] [stderr] error: could not compile `crypto-pals` (bin "crypto-pals" test) due to 20 previous errors; 2 warnings emitted [INFO] [stderr] error: failed to migrate to next edition [INFO] [stderr] [INFO] [stderr] Caused by: [INFO] [stderr] process didn't exit successfully: `cargo fix --edition --allow-no-vcs --allow-dirty --frozen --all --all-targets --message-format=json` (exit status: 101) [INFO] running `Command { std: "docker" "inspect" "1623c794f3cbf2f29dbbdf4b9a3bdcf7635783addc25e837c6635c22cdc2bd35", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "1623c794f3cbf2f29dbbdf4b9a3bdcf7635783addc25e837c6635c22cdc2bd35", kill_on_drop: false }` [INFO] [stdout] 1623c794f3cbf2f29dbbdf4b9a3bdcf7635783addc25e837c6635c22cdc2bd35