[INFO] cloning repository https://github.com/yl2280/ece598pv [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/yl2280/ece598pv" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fyl2280%2Fece598pv", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fyl2280%2Fece598pv'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 7c0488d9de84c00dda9261efcd0e8f0edc9fe099 [INFO] linting yl2280/ece598pv against nightly for clippy-nonminimal_bool-denied [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fyl2280%2Fece598pv" "/workspace/builds/worker-1-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-1-tc1/source'... [INFO] [stderr] done. [INFO] started tweaking git repo https://github.com/yl2280/ece598pv [INFO] finished tweaking git repo https://github.com/yl2280/ece598pv [INFO] tweaked toml for git repo https://github.com/yl2280/ece598pv written to /workspace/builds/worker-1-tc1/source/Cargo.toml [INFO] validating manifest of git repo https://github.com/yl2280/ece598pv on toolchain nightly [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+nightly" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] crate git repo https://github.com/yl2280/ece598pv 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" "+nightly" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Updating crates.io index [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded proc-macro2 v1.0.5 [INFO] [stderr] Downloaded term_size v0.3.1 [INFO] [stderr] Downloaded wasm-bindgen-backend v0.2.51 [INFO] [stderr] Downloaded crossbeam v0.7.2 [INFO] [stderr] Downloaded hex v0.4.0 [INFO] [stderr] Downloaded sourcefile v0.1.4 [INFO] [stderr] Downloaded bincode v1.2.0 [INFO] [stderr] Downloaded untrusted v0.7.0 [INFO] [stderr] Downloaded wasm-bindgen-macro-support v0.2.51 [INFO] [stderr] Downloaded wasm-bindgen-webidl v0.2.51 [INFO] [stderr] Downloaded wasm-bindgen-macro v0.2.51 [INFO] [stderr] Downloaded js-sys v0.3.28 [INFO] [stderr] Downloaded serde_json v1.0.44 [INFO] [stderr] Downloaded crossbeam-channel v0.3.9 [INFO] [stderr] Downloaded weedle v0.10.0 [INFO] [stderr] Downloaded bumpalo v2.6.0 [INFO] [stderr] Downloaded web-sys v0.3.28 [INFO] [stderr] Downloaded nom v4.2.3 [INFO] [stderr] Downloaded wasm-bindgen v0.2.51 [INFO] [stderr] Downloaded hex-literal-impl v0.2.1 [INFO] [stderr] Downloaded hex-literal v0.2.1 [INFO] [stderr] Downloaded wasm-bindgen-shared v0.2.51 [INFO] [stderr] Downloaded chunked_transfer v0.3.1 [INFO] [stderr] Downloaded tiny_http v0.6.2 [INFO] [stderr] Downloaded stderrlog v0.4.1 [INFO] [stderr] Downloaded ascii v0.8.7 [INFO] [stderr] Downloaded ring v0.16.9 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 9aa0d688442ef484bb25f2f141a912c0db07bbe874515f1a31d5ab8f812a1210 [INFO] running `Command { std: "docker" "start" "-a" "9aa0d688442ef484bb25f2f141a912c0db07bbe874515f1a31d5ab8f812a1210", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "9aa0d688442ef484bb25f2f141a912c0db07bbe874515f1a31d5ab8f812a1210", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "9aa0d688442ef484bb25f2f141a912c0db07bbe874515f1a31d5ab8f812a1210", kill_on_drop: false }` [INFO] [stdout] 9aa0d688442ef484bb25f2f141a912c0db07bbe874515f1a31d5ab8f812a1210 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-1-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:d429b63d4308055ea97f60fb1d3dfca48854a00942f1bd2ad806beaf015945ec" "/opt/rustwide/cargo-home/bin/cargo" "+nightly" "clippy" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] ebc91f63c14b537de31668f913b855ec163dae0c0ea4024f76c1fe88bdf8cbbf [INFO] running `Command { std: "docker" "start" "-a" "ebc91f63c14b537de31668f913b855ec163dae0c0ea4024f76c1fe88bdf8cbbf", kill_on_drop: false }` [INFO] [stderr] Compiling autocfg v0.1.6 [INFO] [stderr] Compiling libc v0.2.62 [INFO] [stderr] Compiling proc-macro2 v1.0.5 [INFO] [stderr] Compiling unicode-xid v0.2.0 [INFO] [stderr] Compiling syn v1.0.5 [INFO] [stderr] Checking rand_core v0.4.2 [INFO] [stderr] Compiling semver-parser v0.7.0 [INFO] [stderr] Compiling log v0.4.8 [INFO] [stderr] Checking matches v0.1.8 [INFO] [stderr] Checking smallvec v0.6.10 [INFO] [stderr] Checking rand_core v0.3.1 [INFO] [stderr] Checking crossbeam-utils v0.6.6 [INFO] [stderr] Checking unicode-bidi v0.3.4 [INFO] [stderr] Compiling num-traits v0.2.8 [INFO] [stderr] Compiling num-integer v0.1.41 [INFO] [stderr] Checking unicode-normalization v0.1.8 [INFO] [stderr] Compiling semver v0.9.0 [INFO] [stderr] Compiling arrayvec v0.4.12 [INFO] [stderr] Compiling rustc_version v0.2.3 [INFO] [stderr] Checking nodrop v0.1.14 [INFO] [stderr] Compiling serde v1.0.101 [INFO] [stderr] Checking time v0.1.42 [INFO] [stderr] Compiling rand_pcg v0.1.2 [INFO] [stderr] Compiling rand_chacha v0.1.1 [INFO] [stderr] Compiling memoffset v0.5.1 [INFO] [stderr] Compiling ryu v1.0.2 [INFO] [stderr] Compiling bitflags v1.2.0 [INFO] [stderr] Checking scopeguard v1.0.0 [INFO] [stderr] Compiling cc v1.0.45 [INFO] [stderr] Compiling byteorder v1.3.2 [INFO] [stderr] Checking crossbeam-epoch v0.7.2 [INFO] [stderr] Checking term_size v0.3.1 [INFO] [stderr] Checking net2 v0.2.33 [INFO] [stderr] Compiling quote v1.0.2 [INFO] [stderr] Checking idna v0.1.5 [INFO] [stderr] Checking iovec v0.1.4 [INFO] [stderr] Compiling rand v0.6.5 [INFO] [stderr] Compiling bincode v1.2.0 [INFO] [stderr] Checking unicode-width v0.1.6 [INFO] [stderr] Checking slab v0.4.2 [INFO] [stderr] Checking textwrap v0.11.0 [INFO] [stderr] Checking crossbeam-deque v0.7.1 [INFO] [stderr] Checking mio v0.6.19 [INFO] [stderr] Checking idna v0.2.0 [INFO] [stderr] Checking chrono v0.4.9 [INFO] [stderr] Checking url v1.7.2 [INFO] [stderr] Checking atty v0.2.13 [INFO] [stderr] Checking rand_os v0.1.3 [INFO] [stderr] Checking crossbeam-channel v0.3.9 [INFO] [stderr] Checking crossbeam-queue v0.1.2 [INFO] [stderr] Checking rand_isaac v0.1.1 [INFO] [stderr] Compiling ring v0.16.9 [INFO] [stderr] Checking rand_hc v0.1.0 [INFO] [stderr] Checking rand_xorshift v0.1.1 [INFO] [stderr] Checking rand_jitter v0.1.4 [INFO] [stderr] Checking thread_local v0.3.6 [INFO] [stderr] Checking untrusted v0.7.0 [INFO] [stderr] Checking lazycell v1.2.1 [INFO] [stderr] Checking ascii v0.8.7 [INFO] [stderr] Checking percent-encoding v2.1.0 [INFO] [stderr] Checking strsim v0.8.0 [INFO] [stderr] Checking vec_map v0.8.1 [INFO] [stderr] Checking chunked_transfer v0.3.1 [INFO] [stderr] Checking itoa v0.4.4 [INFO] [stderr] Checking spin v0.5.2 [INFO] [stderr] Checking ansi_term v0.11.0 [INFO] [stderr] Checking url v2.1.0 [INFO] [stderr] Checking stderrlog v0.4.1 [INFO] [stderr] Checking crossbeam v0.7.2 [INFO] [stderr] Checking tiny_http v0.6.2 [INFO] [stderr] Checking mio-extras v2.0.5 [INFO] [stderr] Checking clap v2.33.0 [INFO] [stderr] Checking hex v0.4.0 [INFO] [stderr] Compiling serde_derive v1.0.101 [INFO] [stderr] Compiling proc-macro-hack v0.5.11 [INFO] [stderr] Compiling hex-literal-impl v0.2.1 [INFO] [stderr] Checking hex-literal v0.2.1 [INFO] [stderr] Checking serde_json v1.0.44 [INFO] [stderr] Checking bitcoin v0.1.0 (/opt/rustwide/workdir) [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/api/mod.rs:20:10 [INFO] [stdout] | [INFO] [stdout] 20 | #[derive(Serialize)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: `#[warn(unexpected_cfgs)]` on by default [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:12:10 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:12:21 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:28:10 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:28:21 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/blockchain.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/blockchain.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/hash.rs:11:25 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/hash.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:16:10 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:16:21 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/network/message.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/network/message.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/transaction.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/transaction.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/block.rs:41:17 [INFO] [stdout] | [INFO] [stdout] 41 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: expected names are: `docsrs`, `feature`, and `test` and 31 more [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `deserialize` [INFO] [stdout] --> src/block.rs:4:26 [INFO] [stdout] | [INFO] [stdout] 4 | use bincode::{serialize, deserialize}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `rand::prelude::*` [INFO] [stdout] --> src/block.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | use rand::prelude::*; [INFO] [stdout] | ^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Duration`, `SystemTime`, and `UNIX_EPOCH` [INFO] [stdout] --> src/block.rs:9:17 [INFO] [stdout] | [INFO] [stdout] 9 | use std::time::{Duration, SystemTime, UNIX_EPOCH}; [INFO] [stdout] | ^^^^^^^^ ^^^^^^^^^^ ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `NaiveDateTime` and `NaiveDate` [INFO] [stdout] --> src/block.rs:10:14 [INFO] [stdout] | [INFO] [stdout] 10 | use chrono::{NaiveDate, NaiveDateTime}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/blockchain.rs:111:17 [INFO] [stdout] | [INFO] [stdout] 111 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Header` [INFO] [stdout] --> src/blockchain.rs:1:26 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::block::{Block,Header}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::crypto::merkle::MerkleTree` [INFO] [stdout] --> src/blockchain.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::crypto::merkle::MerkleTree; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `deserialize` and `serialize` [INFO] [stdout] --> src/blockchain.rs:5:15 [INFO] [stdout] | [INFO] [stdout] 5 | use bincode::{serialize, deserialize}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::transaction::Transaction` [INFO] [stdout] --> src/blockchain.rs:6:5 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::transaction::Transaction; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/blockchain.rs:89:21 [INFO] [stdout] | [INFO] [stdout] 89 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/crypto/hash.rs:110:17 [INFO] [stdout] | [INFO] [stdout] 110 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ring::digest::Algorithm` [INFO] [stdout] --> src/crypto/merkle.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use ring::digest::Algorithm; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Duration` [INFO] [stdout] --> src/miner.rs:12:17 [INFO] [stdout] | [INFO] [stdout] 12 | use std::time::{Duration, SystemTime, UNIX_EPOCH}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Hashable` [INFO] [stdout] --> src/network/message.rs:2:27 [INFO] [stdout] | [INFO] [stdout] 2 | use crate::crypto::hash::{Hashable, H256}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `digest` [INFO] [stdout] --> src/network/message.rs:3:12 [INFO] [stdout] | [INFO] [stdout] 3 | use ring::{digest}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Arc` and `Mutex` [INFO] [stdout] --> src/network/message.rs:4:17 [INFO] [stdout] | [INFO] [stdout] 4 | use std::sync::{Arc, Mutex}; [INFO] [stdout] | ^^^ ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Blockchain` [INFO] [stdout] --> src/network/message.rs:5:25 [INFO] [stdout] | [INFO] [stdout] 5 | use crate::blockchain::{Blockchain}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Header` [INFO] [stdout] --> src/network/message.rs:6:26 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::block::{Block,Header}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `H256` [INFO] [stdout] --> src/network/worker.rs:6:37 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::crypto::hash::{Hashable, H256}; [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `digest` [INFO] [stdout] --> src/network/worker.rs:7:12 [INFO] [stdout] | [INFO] [stdout] 7 | use ring::{digest}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Block` and `Header` [INFO] [stdout] --> src/network/worker.rs:10:20 [INFO] [stdout] | [INFO] [stdout] 10 | use crate::block::{Block,Header}; [INFO] [stdout] | ^^^^^ ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/transaction.rs:53:17 [INFO] [stdout] | [INFO] [stdout] 53 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `EdDSAParameters` [INFO] [stdout] --> src/transaction.rs:2:82 [INFO] [stdout] | [INFO] [stdout] 2 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::slice` [INFO] [stdout] --> src/transaction.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::slice; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `deserialize` [INFO] [stdout] --> src/transaction.rs:4:26 [INFO] [stdout] | [INFO] [stdout] 4 | use bincode::{serialize, deserialize}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Rng` and `thread_rng` [INFO] [stdout] --> src/transaction.rs:5:12 [INFO] [stdout] | [INFO] [stdout] 5 | use rand::{thread_rng, Rng}; [INFO] [stdout] | ^^^^^^^^^^ ^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `rand::distributions::Alphanumeric` [INFO] [stdout] --> src/transaction.rs:6:5 [INFO] [stdout] | [INFO] [stdout] 6 | use rand::distributions::Alphanumeric; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/transaction.rs:48:7 [INFO] [stdout] | [INFO] [stdout] 48 | if(ret == Ok(())) { return true;} [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 48 - if(ret == Ok(())) { return true;} [INFO] [stdout] 48 + if ret == Ok(()) { return true;} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/api/mod.rs:20:10 [INFO] [stdout] | [INFO] [stdout] 20 | #[derive(Serialize)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: `#[warn(unexpected_cfgs)]` on by default [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:12:10 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:12:21 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:28:10 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.rs:28:21 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/blockchain.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/blockchain.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/hash.rs:11:25 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/hash.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:16:10 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/crypto/merkle.rs:16:21 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/network/message.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/network/message.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/transaction.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Serialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/transaction.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: expected values for `feature` are: `default` and `test-utilities` [INFO] [stdout] = note: using a cfg inside a derive macro will use the cfgs from the destination crate and not the ones from the defining crate [INFO] [stdout] = help: try referring to `Deserialize` crate for guidance on how handle this unexpected cfg [INFO] [stdout] = help: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/block.rs:41:17 [INFO] [stdout] | [INFO] [stdout] 41 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: expected names are: `docsrs`, `feature`, and `test` and 31 more [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `deserialize` [INFO] [stdout] --> src/block.rs:4:26 [INFO] [stdout] | [INFO] [stdout] 4 | use bincode::{serialize, deserialize}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Duration` [INFO] [stdout] --> src/block.rs:9:17 [INFO] [stdout] | [INFO] [stdout] 9 | use std::time::{Duration, SystemTime, UNIX_EPOCH}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/blockchain.rs:111:17 [INFO] [stdout] | [INFO] [stdout] 111 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Header` [INFO] [stdout] --> src/blockchain.rs:1:26 [INFO] [stdout] | [INFO] [stdout] 1 | use crate::block::{Block,Header}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::crypto::merkle::MerkleTree` [INFO] [stdout] --> src/blockchain.rs:4:5 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::crypto::merkle::MerkleTree; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `deserialize` and `serialize` [INFO] [stdout] --> src/blockchain.rs:5:15 [INFO] [stdout] | [INFO] [stdout] 5 | use bincode::{serialize, deserialize}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::transaction::Transaction` [INFO] [stdout] --> src/blockchain.rs:6:5 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::transaction::Transaction; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/blockchain.rs:89:21 [INFO] [stdout] | [INFO] [stdout] 89 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/crypto/hash.rs:110:17 [INFO] [stdout] | [INFO] [stdout] 110 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `ring::digest::Algorithm` [INFO] [stdout] --> src/crypto/merkle.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use ring::digest::Algorithm; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Duration` [INFO] [stdout] --> src/miner.rs:12:17 [INFO] [stdout] | [INFO] [stdout] 12 | use std::time::{Duration, SystemTime, UNIX_EPOCH}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Hashable` [INFO] [stdout] --> src/network/message.rs:2:27 [INFO] [stdout] | [INFO] [stdout] 2 | use crate::crypto::hash::{Hashable, H256}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `digest` [INFO] [stdout] --> src/network/message.rs:3:12 [INFO] [stdout] | [INFO] [stdout] 3 | use ring::{digest}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Arc` and `Mutex` [INFO] [stdout] --> src/network/message.rs:4:17 [INFO] [stdout] | [INFO] [stdout] 4 | use std::sync::{Arc, Mutex}; [INFO] [stdout] | ^^^ ^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Blockchain` [INFO] [stdout] --> src/network/message.rs:5:25 [INFO] [stdout] | [INFO] [stdout] 5 | use crate::blockchain::{Blockchain}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Header` [INFO] [stdout] --> src/network/message.rs:6:26 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::block::{Block,Header}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `H256` [INFO] [stdout] --> src/network/worker.rs:6:37 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::crypto::hash::{Hashable, H256}; [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `digest` [INFO] [stdout] --> src/network/worker.rs:7:12 [INFO] [stdout] | [INFO] [stdout] 7 | use ring::{digest}; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Block` and `Header` [INFO] [stdout] --> src/network/worker.rs:10:20 [INFO] [stdout] | [INFO] [stdout] 10 | use crate::block::{Block,Header}; [INFO] [stdout] | ^^^^^ ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/transaction.rs:53:17 [INFO] [stdout] | [INFO] [stdout] 53 | #[cfg(any(test, test_utilities))] [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: consider using a Cargo feature instead [INFO] [stdout] = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint: [INFO] [stdout] [lints.rust] [INFO] [stdout] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(test_utilities)'] } [INFO] [stdout] = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(test_utilities)");` to the top of the `build.rs` [INFO] [stdout] = note: see for more information about checking conditional configuration [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `EdDSAParameters` [INFO] [stdout] --> src/transaction.rs:2:82 [INFO] [stdout] | [INFO] [stdout] 2 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::slice` [INFO] [stdout] --> src/transaction.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::slice; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `deserialize` [INFO] [stdout] --> src/transaction.rs:4:26 [INFO] [stdout] | [INFO] [stdout] 4 | use bincode::{serialize, deserialize}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/transaction.rs:48:7 [INFO] [stdout] | [INFO] [stdout] 48 | if(ret == Ok(())) { return true;} [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 48 - if(ret == Ok(())) { return true;} [INFO] [stdout] 48 + if ret == Ok(()) { return true;} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `VerificationAlgorithm` [INFO] [stdout] --> src/transaction.rs:2:59 [INFO] [stdout] | [INFO] [stdout] 2 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `diff_rand` [INFO] [stdout] --> src/blockchain.rs:29:13 [INFO] [stdout] | [INFO] [stdout] 29 | let diff_rand = ::from(rand_u8); [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_diff_rand` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `VerificationAlgorithm` [INFO] [stdout] --> src/transaction.rs:2:59 [INFO] [stdout] | [INFO] [stdout] 2 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> src/crypto/merkle.rs:50:17 [INFO] [stdout] | [INFO] [stdout] 50 | let n = odd.val; [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] --> src/crypto/merkle.rs:60:21 [INFO] [stdout] | [INFO] [stdout] 60 | let n = odd.val; [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `j` is assigned to, but never used [INFO] [stdout] --> src/crypto/merkle.rs:109:13 [INFO] [stdout] | [INFO] [stdout] 109 | let mut j = 0; [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_j` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `j` is never read [INFO] [stdout] --> src/crypto/merkle.rs:113:13 [INFO] [stdout] | [INFO] [stdout] 113 | j += 1; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `leaf_size` [INFO] [stdout] --> src/crypto/merkle.rs:153:72 [INFO] [stdout] | [INFO] [stdout] 153 | pub fn verify(root: &H256, datum: &H256, proof: &[H256], index: usize, leaf_size: usize) -> bool { [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_leaf_size` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `now` [INFO] [stdout] --> src/miner.rs:147:17 [INFO] [stdout] | [INFO] [stdout] 147 | let now = Utc::now(); [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_now` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `date_time` [INFO] [stdout] --> src/block.rs:51:13 [INFO] [stdout] | [INFO] [stdout] 51 | let date_time: NaiveDateTime = NaiveDate::from_ymd(2017, 11, 12).and_hms(17, 33, 44); [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_date_time` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `diff_rand` [INFO] [stdout] --> src/blockchain.rs:29:13 [INFO] [stdout] | [INFO] [stdout] 29 | let diff_rand = ::from(rand_u8); [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_diff_rand` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `block_m` [INFO] [stdout] --> src/network/worker.rs:28:9 [INFO] [stdout] | [INFO] [stdout] 28 | let block_m = Arc::new(Mutex::new(block)); [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_block_m` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:84:25 [INFO] [stdout] | [INFO] [stdout] 84 | let mut nonce = blk.clone(); [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:104:25 [INFO] [stdout] | [INFO] [stdout] 104 | let mut nonce = blk.clone(); [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `n` [INFO] [stdout] --> src/crypto/merkle.rs:50:17 [INFO] [stdout] | [INFO] [stdout] 50 | let n = odd.val; [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] --> src/crypto/merkle.rs:60:21 [INFO] [stdout] | [INFO] [stdout] 60 | let n = odd.val; [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_n` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `j` is assigned to, but never used [INFO] [stdout] --> src/crypto/merkle.rs:109:13 [INFO] [stdout] | [INFO] [stdout] 109 | let mut j = 0; [INFO] [stdout] | ^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_j` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `j` is never read [INFO] [stdout] --> src/crypto/merkle.rs:113:13 [INFO] [stdout] | [INFO] [stdout] 113 | j += 1; [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `leaf_size` [INFO] [stdout] --> src/crypto/merkle.rs:153:72 [INFO] [stdout] | [INFO] [stdout] 153 | pub fn verify(root: &H256, datum: &H256, proof: &[H256], index: usize, leaf_size: usize) -> bool { [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_leaf_size` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `a` [INFO] [stdout] --> src/crypto/merkle.rs:204:13 [INFO] [stdout] | [INFO] [stdout] 204 | let a = input_data[0].hash(); [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_a` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `b` [INFO] [stdout] --> src/crypto/merkle.rs:205:13 [INFO] [stdout] | [INFO] [stdout] 205 | let b = input_data[1].hash(); [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_b` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `server` is never read [INFO] [stdout] --> src/network/worker.rs:17:5 [INFO] [stdout] | [INFO] [stdout] 14 | pub struct Context { [INFO] [stdout] | ------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 17 | server: ServerHandle, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Context` has a derived impl for the trait `Clone`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `now` [INFO] [stdout] --> src/miner.rs:147:17 [INFO] [stdout] | [INFO] [stdout] 147 | let now = Utc::now(); [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_now` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/api/mod.rs:45:39 [INFO] [stdout] | [INFO] [stdout] 45 | let handle = HTTPServer::http(&addr).unwrap(); [INFO] [stdout] | ^^^^^ help: change this to: `addr` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] = note: `#[warn(clippy::needless_borrows_for_generic_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `block_m` [INFO] [stdout] --> src/network/worker.rs:28:9 [INFO] [stdout] | [INFO] [stdout] 28 | let block_m = Arc::new(Mutex::new(block)); [INFO] [stdout] | ^^^^^^^ help: if this is intentional, prefix it with an underscore: `_block_m` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:84:25 [INFO] [stdout] | [INFO] [stdout] 84 | let mut nonce = blk.clone(); [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:104:25 [INFO] [stdout] | [INFO] [stdout] 104 | let mut nonce = blk.clone(); [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `s` [INFO] [stdout] --> src/transaction.rs:70:13 [INFO] [stdout] | [INFO] [stdout] 70 | let s = ""; [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_s` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `server` is never read [INFO] [stdout] --> src/network/worker.rs:17:5 [INFO] [stdout] | [INFO] [stdout] 14 | pub struct Context { [INFO] [stdout] | ------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 17 | server: ServerHandle, [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `Context` has a derived impl for the trait `Clone`, but this is intentionally ignored during dead code analysis [INFO] [stdout] = note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:88:9 [INFO] [stdout] | [INFO] [stdout] 88 | return MerkleTree{root: Some(Box::new(r)), tree: Some(Box::new(t))}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 88 - return MerkleTree{root: Some(Box::new(r)), tree: Some(Box::new(t))}; [INFO] [stdout] 88 + MerkleTree{root: Some(Box::new(r)), tree: Some(Box::new(t))} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/crypto/merkle.rs:28:12 [INFO] [stdout] | [INFO] [stdout] 28 | if data.len() == 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `data.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: the borrowed expression implements the required traits [INFO] [stdout] --> src/api/mod.rs:45:39 [INFO] [stdout] | [INFO] [stdout] 45 | let handle = HTTPServer::http(&addr).unwrap(); [INFO] [stdout] | ^^^^^ help: change this to: `addr` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args [INFO] [stdout] = note: `#[warn(clippy::needless_borrows_for_generic_args)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/crypto/merkle.rs:64:19 [INFO] [stdout] | [INFO] [stdout] 64 | while vec.len()!= 0{ [INFO] [stdout] | ^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:73:35 [INFO] [stdout] | [INFO] [stdout] 73 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `l2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] = note: `#[warn(clippy::redundant_slicing)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:73:44 [INFO] [stdout] | [INFO] [stdout] 73 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `r2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:96:9 [INFO] [stdout] | [INFO] [stdout] 96 | return **r; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 96 - return **r; [INFO] [stdout] 96 + **r [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:146:9 [INFO] [stdout] | [INFO] [stdout] 146 | return vec; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 146 - return vec; [INFO] [stdout] 146 + vec [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:182:5 [INFO] [stdout] | [INFO] [stdout] 182 | return *root == ret; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 182 - return *root == ret; [INFO] [stdout] 182 + *root == ret [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `H256` which implements the `Copy` trait [INFO] [stdout] --> src/crypto/merkle.rs:156:19 [INFO] [stdout] | [INFO] [stdout] 156 | let mut ret = datum.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*datum` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] = note: `#[warn(clippy::clone_on_copy)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/crypto/merkle.rs:158:11 [INFO] [stdout] | [INFO] [stdout] 158 | while vec.len() > 0{ [INFO] [stdout] | ^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:164:27 [INFO] [stdout] | [INFO] [stdout] 164 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `l2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:164:36 [INFO] [stdout] | [INFO] [stdout] 164 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `r2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manually reimplementing `div_ceil` [INFO] [stdout] --> src/crypto/merkle.rs:167:17 [INFO] [stdout] | [INFO] [stdout] 167 | i = (i+1)/2; [INFO] [stdout] | ^^^^^^^ help: consider using `.div_ceil()`: `i.div_ceil(2)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_div_ceil [INFO] [stdout] = note: `#[warn(clippy::manual_div_ceil)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:175:27 [INFO] [stdout] | [INFO] [stdout] 175 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `l2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:175:36 [INFO] [stdout] | [INFO] [stdout] 175 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `r2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `&[u8]` [INFO] [stdout] --> src/crypto/key_pair.rs:8:32 [INFO] [stdout] | [INFO] [stdout] 8 | Ed25519KeyPair::from_pkcs8(pkcs8_bytes.as_ref().into()).unwrap() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into()`: `pkcs8_bytes.as_ref()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded late initialization [INFO] [stdout] --> src/miner.rs:132:13 [INFO] [stdout] | [INFO] [stdout] 132 | let diff; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_late_init [INFO] [stdout] = note: `#[warn(clippy::needless_late_init)]` on by default [INFO] [stdout] help: move the declaration `diff` here and remove the assignments from the branches [INFO] [stdout] | [INFO] [stdout] 132 ~ [INFO] [stdout] 133 ~ let diff = if self.blockchain.lock().unwrap().map.get(&parent).is_some(){ [INFO] [stdout] 134 ~ self.blockchain.lock().unwrap().map.get(&parent).unwrap().header.as_ref().unwrap().difficulty [INFO] [stdout] 135 | } [INFO] [stdout] 136 | else{ [INFO] [stdout] 137 ~ diff_rand [INFO] [stdout] 138 ~ }; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&parent).is_some()` [INFO] [stdout] --> src/miner.rs:133:53 [INFO] [stdout] | [INFO] [stdout] 133 | if self.blockchain.lock().unwrap().map.get(&parent).is_some(){ [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `contains_key(&parent)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] = note: `#[warn(clippy::unnecessary_get_then_check)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded late initialization [INFO] [stdout] --> src/miner.rs:140:13 [INFO] [stdout] | [INFO] [stdout] 140 | let in_ms:u64; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_late_init [INFO] [stdout] help: move the declaration `in_ms` here and remove the assignments from the `match` arms [INFO] [stdout] | [INFO] [stdout] 140 ~ [INFO] [stdout] 141 ~ let in_ms:u64 = match SystemTime::now().duration_since(UNIX_EPOCH) { [INFO] [stdout] 142 ~ Ok(n) => n.as_secs() * 1000 + n.subsec_nanos() as u64 / 1000000, [INFO] [stdout] 143 | Err(_) => panic!("SystemTime before UNIX EPOCH!"), [INFO] [stdout] 144 ~ }; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/miner.rs:164:17 [INFO] [stdout] | [INFO] [stdout] 164 | count = count + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace it with: `count += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `H256` which implements the `Copy` trait [INFO] [stdout] --> src/miner.rs:171:30 [INFO] [stdout] | [INFO] [stdout] 171 | vec.push(i.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`) [INFO] [stdout] --> src/miner.rs:192:64 [INFO] [stdout] | [INFO] [stdout] 192 | let interval = time::Duration::from_micros(i as u64); [INFO] [stdout] | ^^^^^^^^ help: try: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/block.rs:67:9 [INFO] [stdout] | [INFO] [stdout] 67 | / return Block{ [INFO] [stdout] 68 | | header: Some(Box::new(head)), [INFO] [stdout] 69 | | content: None, [INFO] [stdout] 70 | | height: 0, [INFO] [stdout] 71 | | }; [INFO] [stdout] | |_________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] = note: `#[warn(clippy::needless_return)]` on by default [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 67 ~ Block{ [INFO] [stdout] 68 ~ header: Some(Box::new(head)), [INFO] [stdout] 69 ~ content: None, [INFO] [stdout] 70 + height: 0, [INFO] [stdout] 71 ~ } [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded late initialization [INFO] [stdout] --> src/block.rs:52:9 [INFO] [stdout] | [INFO] [stdout] 52 | let in_ms:u64; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_late_init [INFO] [stdout] = note: `#[warn(clippy::needless_late_init)]` on by default [INFO] [stdout] help: move the declaration `in_ms` here and remove the assignments from the `match` arms [INFO] [stdout] | [INFO] [stdout] 52 ~ [INFO] [stdout] 53 ~ let in_ms:u64 = match SystemTime::now().duration_since(UNIX_EPOCH) { [INFO] [stdout] 54 ~ Ok(n) => n.as_secs() * 1000 + n.subsec_nanos() as u64 / 1000000, [INFO] [stdout] 55 | Err(_) => panic!("SystemTime before UNIX EPOCH!"), [INFO] [stdout] 56 ~ }; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/blockchain.rs:105:9 [INFO] [stdout] | [INFO] [stdout] 105 | return ret; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 105 - return ret; [INFO] [stdout] 105 + ret [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/blockchain.rs:102:37 [INFO] [stdout] | [INFO] [stdout] 102 | parant_b = self.map.get(&key); [INFO] [stdout] | ^^^^ help: change this to: `key` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/network/server.rs:65:24 [INFO] [stdout] | [INFO] [stdout] 65 | return Err(std::io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 66 | | std::io::ErrorKind::Other, [INFO] [stdout] 67 | | "max peer reached, cannot accept new connections", [INFO] [stdout] 68 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] = note: `#[warn(clippy::io_other_error)]` on by default [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 65 ~ return Err(std::io::Error::other( [INFO] [stdout] 66 ~ "max peer reached, cannot accept new connections", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of a legacy numeric constant [INFO] [stdout] --> src/network/server.rs:264:49 [INFO] [stdout] | [INFO] [stdout] 264 | const INCOMING: mio::Token = mio::Token(std::usize::MAX - 1); [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] = note: `#[warn(clippy::legacy_numeric_constants)]` on by default [INFO] [stdout] help: use the associated constant instead [INFO] [stdout] | [INFO] [stdout] 264 - const INCOMING: mio::Token = mio::Token(std::usize::MAX - 1); [INFO] [stdout] 264 + const INCOMING: mio::Token = mio::Token(usize::MAX - 1); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of a legacy numeric constant [INFO] [stdout] --> src/network/server.rs:273:48 [INFO] [stdout] | [INFO] [stdout] 273 | const CONTROL: mio::Token = mio::Token(std::usize::MAX - 2); [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] help: use the associated constant instead [INFO] [stdout] | [INFO] [stdout] 273 - const CONTROL: mio::Token = mio::Token(std::usize::MAX - 2); [INFO] [stdout] 273 + const CONTROL: mio::Token = mio::Token(usize::MAX - 2); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:88:9 [INFO] [stdout] | [INFO] [stdout] 88 | return MerkleTree{root: Some(Box::new(r)), tree: Some(Box::new(t))}; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 88 - return MerkleTree{root: Some(Box::new(r)), tree: Some(Box::new(t))}; [INFO] [stdout] 88 + MerkleTree{root: Some(Box::new(r)), tree: Some(Box::new(t))} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/crypto/merkle.rs:28:12 [INFO] [stdout] | [INFO] [stdout] 28 | if data.len() == 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^^ help: using `is_empty` is clearer and more explicit: `data.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] = note: `#[warn(clippy::len_zero)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/crypto/merkle.rs:64:19 [INFO] [stdout] | [INFO] [stdout] 64 | while vec.len()!= 0{ [INFO] [stdout] | ^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:73:35 [INFO] [stdout] | [INFO] [stdout] 73 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `l2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] = note: `#[warn(clippy::redundant_slicing)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/network/worker.rs:88:32 [INFO] [stdout] | [INFO] [stdout] 88 | ... if !blockchain.map.get(&i).is_none(){ [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `blockchain.map.get(&i).is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:73:44 [INFO] [stdout] | [INFO] [stdout] 73 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `r2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:96:9 [INFO] [stdout] | [INFO] [stdout] 96 | return **r; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 96 - return **r; [INFO] [stdout] 96 + **r [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:146:9 [INFO] [stdout] | [INFO] [stdout] 146 | return vec; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 146 - return vec; [INFO] [stdout] 146 + vec [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/network/worker.rs:66:24 [INFO] [stdout] | [INFO] [stdout] 66 | if nonce.len() != 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!nonce.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&i).is_none()` [INFO] [stdout] --> src/network/worker.rs:69:68 [INFO] [stdout] | [INFO] [stdout] 69 | ... if self.blockchain.lock().unwrap().map.get(&i).is_none(){ [INFO] [stdout] | ------------------------------------^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: replace it with: `!self.blockchain.lock().unwrap().map.contains_key(&i)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:69:72 [INFO] [stdout] | [INFO] [stdout] 69 | ... if self.blockchain.lock().unwrap().map.get(&i).is_none(){ [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] = note: `#[warn(clippy::needless_borrow)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/network/worker.rs:74:28 [INFO] [stdout] | [INFO] [stdout] 74 | if vec.len() != 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/crypto/merkle.rs:182:5 [INFO] [stdout] | [INFO] [stdout] 182 | return *root == ret; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 182 - return *root == ret; [INFO] [stdout] 182 + *root == ret [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&i).is_none()` [INFO] [stdout] --> src/network/worker.rs:88:48 [INFO] [stdout] | [INFO] [stdout] 88 | ... if !blockchain.map.get(&i).is_none(){ [INFO] [stdout] | ---------------^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: replace it with: `!blockchain.map.contains_key(&i)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:88:52 [INFO] [stdout] | [INFO] [stdout] 88 | ... if !blockchain.map.get(&i).is_none(){ [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:91:61 [INFO] [stdout] | [INFO] [stdout] 91 | ... vec.push(blockchain.map.get(&i).unwrap().clone()); [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/network/worker.rs:94:28 [INFO] [stdout] | [INFO] [stdout] 94 | if vec.len() != 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&i.hash()).is_none()` [INFO] [stdout] --> src/network/worker.rs:107:43 [INFO] [stdout] | [INFO] [stdout] 107 | if blockchain.map.get(&i.hash()).is_none(){ [INFO] [stdout] | ---------------^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: replace it with: `!blockchain.map.contains_key(&i.hash())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:108:47 [INFO] [stdout] | [INFO] [stdout] 108 | ... blockchain.insert(&i); [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `H256` which implements the `Copy` trait [INFO] [stdout] --> src/crypto/merkle.rs:156:19 [INFO] [stdout] | [INFO] [stdout] 156 | let mut ret = datum.clone(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: try dereferencing it: `*datum` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] = note: `#[warn(clippy::clone_on_copy)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/crypto/merkle.rs:158:11 [INFO] [stdout] | [INFO] [stdout] 158 | while vec.len() > 0{ [INFO] [stdout] | ^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:164:27 [INFO] [stdout] | [INFO] [stdout] 164 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `l2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:164:36 [INFO] [stdout] | [INFO] [stdout] 164 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `r2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manually reimplementing `div_ceil` [INFO] [stdout] --> src/crypto/merkle.rs:167:17 [INFO] [stdout] | [INFO] [stdout] 167 | i = (i+1)/2; [INFO] [stdout] | ^^^^^^^ help: consider using `.div_ceil()`: `i.div_ceil(2)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_div_ceil [INFO] [stdout] = note: `#[warn(clippy::manual_div_ceil)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:175:27 [INFO] [stdout] | [INFO] [stdout] 175 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `l2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/transaction.rs:34:5 [INFO] [stdout] | [INFO] [stdout] 34 | return sig; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 34 - return sig; [INFO] [stdout] 34 + sig [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: redundant slicing of the whole range [INFO] [stdout] --> src/crypto/merkle.rs:175:36 [INFO] [stdout] | [INFO] [stdout] 175 | let parent = [&l2[..], &r2[..]].concat(); [INFO] [stdout] | ^^^^^^^ help: use the original value instead: `r2` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/transaction.rs:48:25 [INFO] [stdout] | [INFO] [stdout] 48 | if(ret == Ok(())) { return true;} [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 48 - if(ret == Ok(())) { return true;} [INFO] [stdout] 48 + if(ret == Ok(())) { true} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/transaction.rs:49:11 [INFO] [stdout] | [INFO] [stdout] 49 | else {return false;} [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 49 - else {return false;} [INFO] [stdout] 49 + else {false} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this if-then-else expression returns a bool literal [INFO] [stdout] --> src/transaction.rs:48:5 [INFO] [stdout] | [INFO] [stdout] 48 | / if(ret == Ok(())) { return true;} [INFO] [stdout] 49 | | else {return false;} [INFO] [stdout] | |________________________^ help: you can reduce it to: `return ret == Ok(())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bool [INFO] [stdout] = note: `#[warn(clippy::needless_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: useless conversion to the same type: `&[u8]` [INFO] [stdout] --> src/crypto/key_pair.rs:8:32 [INFO] [stdout] | [INFO] [stdout] 8 | Ed25519KeyPair::from_pkcs8(pkcs8_bytes.as_ref().into()).unwrap() [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into()`: `pkcs8_bytes.as_ref()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion [INFO] [stdout] = note: `#[warn(clippy::useless_conversion)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/api/mod.rs:20:10 [INFO] [stdout] | [INFO] [stdout] 20 | #[derive(Serialize)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_ApiResponse` [INFO] [stdout] 21 | struct ApiResponse { [INFO] [stdout] | ----------- `ApiResponse` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: `#[warn(non_local_definitions)]` on by default [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:12:10 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Header` [INFO] [stdout] 13 | pub struct Header { [INFO] [stdout] | ------ `Header` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:12:21 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Header` [INFO] [stdout] 13 | pub struct Header { [INFO] [stdout] | ------ `Header` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:28:10 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Block` [INFO] [stdout] 29 | pub struct Block { [INFO] [stdout] | ----- `Block` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:28:21 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Block` [INFO] [stdout] 29 | pub struct Block { [INFO] [stdout] | ----- `Block` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `genesisBlock` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:13:6 [INFO] [stdout] | [INFO] [stdout] 13 | genesisBlock: Option, [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `genesis_block` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/blockchain.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Blockchain` [INFO] [stdout] 12 | pub struct Blockchain { [INFO] [stdout] | ---------- `Blockchain` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded late initialization [INFO] [stdout] --> src/miner.rs:132:13 [INFO] [stdout] | [INFO] [stdout] 132 | let diff; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_late_init [INFO] [stdout] help: move the declaration `diff` here and remove the assignments from the branches [INFO] [stdout] | [INFO] [stdout] 132 ~ [INFO] [stdout] 133 ~ let diff = if self.blockchain.lock().unwrap().map.get(&parent).is_some(){ [INFO] [stdout] 134 ~ self.blockchain.lock().unwrap().map.get(&parent).unwrap().header.as_ref().unwrap().difficulty [INFO] [stdout] 135 | } [INFO] [stdout] 136 | else{ [INFO] [stdout] 137 ~ diff_rand [INFO] [stdout] 138 ~ }; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/blockchain.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Blockchain` [INFO] [stdout] 12 | pub struct Blockchain { [INFO] [stdout] | ---------- `Blockchain` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&parent).is_some()` [INFO] [stdout] --> src/miner.rs:133:53 [INFO] [stdout] | [INFO] [stdout] 133 | if self.blockchain.lock().unwrap().map.get(&parent).is_some(){ [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^ help: replace it with: `contains_key(&parent)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] = note: `#[warn(clippy::unnecessary_get_then_check)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded late initialization [INFO] [stdout] --> src/miner.rs:140:13 [INFO] [stdout] | [INFO] [stdout] 140 | let in_ms:u64; [INFO] [stdout] | ^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_late_init [INFO] [stdout] help: move the declaration `in_ms` here and remove the assignments from the `match` arms [INFO] [stdout] | [INFO] [stdout] 140 ~ [INFO] [stdout] 141 ~ let in_ms:u64 = match SystemTime::now().duration_since(UNIX_EPOCH) { [INFO] [stdout] 142 ~ Ok(n) => n.as_secs() * 1000 + n.subsec_nanos() as u64 / 1000000, [INFO] [stdout] 143 | Err(_) => panic!("SystemTime before UNIX EPOCH!"), [INFO] [stdout] 144 ~ }; [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/hash.rs:11:25 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_H256` [INFO] [stdout] 12 | pub struct H256([u8; 32]); // big endian u256 [INFO] [stdout] | ---- `H256` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/hash.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_H256` [INFO] [stdout] 12 | pub struct H256([u8; 32]); // big endian u256 [INFO] [stdout] | ---- `H256` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Node` [INFO] [stdout] 9 | struct Node { [INFO] [stdout] | ---- `Node` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Node` [INFO] [stdout] 9 | struct Node { [INFO] [stdout] | ---- `Node` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: manual implementation of an assign operation [INFO] [stdout] --> src/miner.rs:164:17 [INFO] [stdout] | [INFO] [stdout] 164 | count = count + 1; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ help: replace it with: `count += 1` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#assign_op_pattern [INFO] [stdout] = note: `#[warn(clippy::assign_op_pattern)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: using `clone` on type `H256` which implements the `Copy` trait [INFO] [stdout] --> src/miner.rs:171:30 [INFO] [stdout] | [INFO] [stdout] 171 | vec.push(i.clone()); [INFO] [stdout] | ^^^^^^^^^ help: try dereferencing it: `*i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:16:10 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_MerkleTree` [INFO] [stdout] 17 | pub struct MerkleTree { [INFO] [stdout] | ---------- `MerkleTree` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:16:21 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_MerkleTree` [INFO] [stdout] 17 | pub struct MerkleTree { [INFO] [stdout] | ---------- `MerkleTree` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `parentH` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:74:25 [INFO] [stdout] | [INFO] [stdout] 74 | let parentH = digest::digest(&digest::SHA256, &parent); [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `parent_h` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `newNode` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:76:25 [INFO] [stdout] | [INFO] [stdout] 76 | let newNode:Node = Node{val, l: Some(Box::new(l1)), r: Some(Box::new(r1))}; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `new_node` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: casting to the same type is unnecessary (`u64` -> `u64`) [INFO] [stdout] --> src/miner.rs:192:64 [INFO] [stdout] | [INFO] [stdout] 192 | let interval = time::Duration::from_micros(i as u64); [INFO] [stdout] | ^^^^^^^^ help: try: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [INFO] [stdout] = note: `#[warn(clippy::unnecessary_cast)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `sibV` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:127:21 [INFO] [stdout] | [INFO] [stdout] 127 | let sibV = sibiling.val; [INFO] [stdout] | ^^^^ help: convert the identifier to snake case: `sib_v` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `sibV` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:139:21 [INFO] [stdout] | [INFO] [stdout] 139 | let sibV = sibiling.val; [INFO] [stdout] | ^^^^ help: convert the identifier to snake case: `sib_v` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: call to `.clone()` on a reference in this situation does nothing [INFO] [stdout] --> src/crypto/merkle.rs:157:34 [INFO] [stdout] | [INFO] [stdout] 157 | let mut vec = Vec::from(proof.clone()); [INFO] [stdout] | ^^^^^^^^ help: remove this redundant call [INFO] [stdout] | [INFO] [stdout] = note: the type `[crypto::hash::H256]` does not implement `Clone`, so calling `clone` on `&[crypto::hash::H256]` copies the reference, which does not do anything and can be removed [INFO] [stdout] = note: `#[warn(noop_method_call)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `parentH` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:165:17 [INFO] [stdout] | [INFO] [stdout] 165 | let parentH = digest::digest(&digest::SHA256, &parent); [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `parent_h` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `parentH` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:176:17 [INFO] [stdout] | [INFO] [stdout] 176 | let parentH = digest::digest(&digest::SHA256, &parent); [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `parent_h` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/network/message.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Message` [INFO] [stdout] 9 | pub enum Message { [INFO] [stdout] | ------- `Message` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/network/message.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Message` [INFO] [stdout] 9 | pub enum Message { [INFO] [stdout] | ------- `Message` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/transaction.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Transaction` [INFO] [stdout] 12 | pub struct Transaction { [INFO] [stdout] | ----------- `Transaction` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/transaction.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Transaction` [INFO] [stdout] 12 | pub struct Transaction { [INFO] [stdout] | ----------- `Transaction` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this can be `std::io::Error::other(_)` [INFO] [stdout] --> src/network/server.rs:65:24 [INFO] [stdout] | [INFO] [stdout] 65 | return Err(std::io::Error::new( [INFO] [stdout] | ________________________^ [INFO] [stdout] 66 | | std::io::ErrorKind::Other, [INFO] [stdout] 67 | | "max peer reached, cannot accept new connections", [INFO] [stdout] 68 | | )); [INFO] [stdout] | |_____________^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#io_other_error [INFO] [stdout] = note: `#[warn(clippy::io_other_error)]` on by default [INFO] [stdout] help: use `std::io::Error::other` [INFO] [stdout] | [INFO] [stdout] 65 ~ return Err(std::io::Error::other( [INFO] [stdout] 66 ~ "max peer reached, cannot accept new connections", [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of a legacy numeric constant [INFO] [stdout] --> src/network/server.rs:264:49 [INFO] [stdout] | [INFO] [stdout] 264 | const INCOMING: mio::Token = mio::Token(std::usize::MAX - 1); [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] = note: `#[warn(clippy::legacy_numeric_constants)]` on by default [INFO] [stdout] help: use the associated constant instead [INFO] [stdout] | [INFO] [stdout] 264 - const INCOMING: mio::Token = mio::Token(std::usize::MAX - 1); [INFO] [stdout] 264 + const INCOMING: mio::Token = mio::Token(usize::MAX - 1); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: usage of a legacy numeric constant [INFO] [stdout] --> src/network/server.rs:273:48 [INFO] [stdout] | [INFO] [stdout] 273 | const CONTROL: mio::Token = mio::Token(std::usize::MAX - 2); [INFO] [stdout] | ^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#legacy_numeric_constants [INFO] [stdout] help: use the associated constant instead [INFO] [stdout] | [INFO] [stdout] 273 - const CONTROL: mio::Token = mio::Token(std::usize::MAX - 2); [INFO] [stdout] 273 + const CONTROL: mio::Token = mio::Token(usize::MAX - 2); [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this boolean expression can be simplified [INFO] [stdout] --> src/network/worker.rs:88:32 [INFO] [stdout] | [INFO] [stdout] 88 | ... if !blockchain.map.get(&i).is_none(){ [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `blockchain.map.get(&i).is_some()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool [INFO] [stdout] = note: `#[warn(clippy::nonminimal_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/network/worker.rs:66:24 [INFO] [stdout] | [INFO] [stdout] 66 | if nonce.len() != 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!nonce.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&i).is_none()` [INFO] [stdout] --> src/network/worker.rs:69:68 [INFO] [stdout] | [INFO] [stdout] 69 | ... if self.blockchain.lock().unwrap().map.get(&i).is_none(){ [INFO] [stdout] | ------------------------------------^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: replace it with: `!self.blockchain.lock().unwrap().map.contains_key(&i)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:69:72 [INFO] [stdout] | [INFO] [stdout] 69 | ... if self.blockchain.lock().unwrap().map.get(&i).is_none(){ [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/network/worker.rs:74:28 [INFO] [stdout] | [INFO] [stdout] 74 | if vec.len() != 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&i).is_none()` [INFO] [stdout] --> src/network/worker.rs:88:48 [INFO] [stdout] | [INFO] [stdout] 88 | ... if !blockchain.map.get(&i).is_none(){ [INFO] [stdout] | ---------------^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: replace it with: `!blockchain.map.contains_key(&i)` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:88:52 [INFO] [stdout] | [INFO] [stdout] 88 | ... if !blockchain.map.get(&i).is_none(){ [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:91:61 [INFO] [stdout] | [INFO] [stdout] 91 | ... vec.push(blockchain.map.get(&i).unwrap().clone()); [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: length comparison to zero [INFO] [stdout] --> src/network/worker.rs:94:28 [INFO] [stdout] | [INFO] [stdout] 94 | if vec.len() != 0{ [INFO] [stdout] | ^^^^^^^^^^^^^^ help: using `!is_empty` is clearer and more explicit: `!vec.is_empty()` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_zero [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary use of `get(&i.hash()).is_none()` [INFO] [stdout] --> src/network/worker.rs:107:43 [INFO] [stdout] | [INFO] [stdout] 107 | if blockchain.map.get(&i.hash()).is_none(){ [INFO] [stdout] | ---------------^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: replace it with: `!blockchain.map.contains_key(&i.hash())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_get_then_check [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/network/worker.rs:108:47 [INFO] [stdout] | [INFO] [stdout] 108 | ... blockchain.insert(&i); [INFO] [stdout] | ^^ help: change this to: `i` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/transaction.rs:34:5 [INFO] [stdout] | [INFO] [stdout] 34 | return sig; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 34 - return sig; [INFO] [stdout] 34 + sig [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/transaction.rs:48:25 [INFO] [stdout] | [INFO] [stdout] 48 | if(ret == Ok(())) { return true;} [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 48 - if(ret == Ok(())) { return true;} [INFO] [stdout] 48 + if(ret == Ok(())) { true} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/transaction.rs:49:11 [INFO] [stdout] | [INFO] [stdout] 49 | else {return false;} [INFO] [stdout] | ^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 49 - else {return false;} [INFO] [stdout] 49 + else {false} [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this if-then-else expression returns a bool literal [INFO] [stdout] --> src/transaction.rs:48:5 [INFO] [stdout] | [INFO] [stdout] 48 | / if(ret == Ok(())) { return true;} [INFO] [stdout] 49 | | else {return false;} [INFO] [stdout] | |________________________^ help: you can reduce it to: `return ret == Ok(())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_bool [INFO] [stdout] = note: `#[warn(clippy::needless_bool)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unneeded `return` statement [INFO] [stdout] --> src/transaction.rs:76:9 [INFO] [stdout] | [INFO] [stdout] 76 | return ret; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return [INFO] [stdout] help: remove `return` [INFO] [stdout] | [INFO] [stdout] 76 - return ret; [INFO] [stdout] 76 + ret [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: this expression creates a reference which is immediately dereferenced by the compiler [INFO] [stdout] --> src/transaction.rs:85:28 [INFO] [stdout] | [INFO] [stdout] 85 | assert!(verify(&t, &(key.public_key()), &signature)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ help: change this to: `(key.public_key())` [INFO] [stdout] | [INFO] [stdout] = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/api/mod.rs:20:10 [INFO] [stdout] | [INFO] [stdout] 20 | #[derive(Serialize)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_ApiResponse` [INFO] [stdout] 21 | struct ApiResponse { [INFO] [stdout] | ----------- `ApiResponse` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: `#[warn(non_local_definitions)]` on by default [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:12:10 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Header` [INFO] [stdout] 13 | pub struct Header { [INFO] [stdout] | ------ `Header` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:12:21 [INFO] [stdout] | [INFO] [stdout] 12 | #[derive(Serialize, Deserialize,Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Header` [INFO] [stdout] 13 | pub struct Header { [INFO] [stdout] | ------ `Header` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:28:10 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Block` [INFO] [stdout] 29 | pub struct Block { [INFO] [stdout] | ----- `Block` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:28:21 [INFO] [stdout] | [INFO] [stdout] 28 | #[derive(Serialize, Deserialize, Debug, Clone, PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Block` [INFO] [stdout] 29 | pub struct Block { [INFO] [stdout] | ----- `Block` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `genesisBlock` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:13:6 [INFO] [stdout] | [INFO] [stdout] 13 | genesisBlock: Option, [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `genesis_block` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` (part of `#[warn(nonstandard_style)]`) on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/blockchain.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Blockchain` [INFO] [stdout] 12 | pub struct Blockchain { [INFO] [stdout] | ---------- `Blockchain` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/blockchain.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize,Debug, Default)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Blockchain` [INFO] [stdout] 12 | pub struct Blockchain { [INFO] [stdout] | ---------- `Blockchain` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/hash.rs:11:25 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_H256` [INFO] [stdout] 12 | pub struct H256([u8; 32]); // big endian u256 [INFO] [stdout] | ---- `H256` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/hash.rs:11:36 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Eq, PartialEq, Serialize, Deserialize, Clone, Hash, Default, Copy)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_H256` [INFO] [stdout] 12 | pub struct H256([u8; 32]); // big endian u256 [INFO] [stdout] | ---- `H256` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Node` [INFO] [stdout] 9 | struct Node { [INFO] [stdout] | ---- `Node` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize,Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Node` [INFO] [stdout] 9 | struct Node { [INFO] [stdout] | ---- `Node` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:16:10 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_MerkleTree` [INFO] [stdout] 17 | pub struct MerkleTree { [INFO] [stdout] | ---------- `MerkleTree` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/crypto/merkle.rs:16:21 [INFO] [stdout] | [INFO] [stdout] 16 | #[derive(Serialize, Deserialize, Debug, Default, Clone,PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_MerkleTree` [INFO] [stdout] 17 | pub struct MerkleTree { [INFO] [stdout] | ---------- `MerkleTree` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `parentH` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:74:25 [INFO] [stdout] | [INFO] [stdout] 74 | let parentH = digest::digest(&digest::SHA256, &parent); [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `parent_h` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `newNode` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:76:25 [INFO] [stdout] | [INFO] [stdout] 76 | let newNode:Node = Node{val, l: Some(Box::new(l1)), r: Some(Box::new(r1))}; [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `new_node` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `sibV` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:127:21 [INFO] [stdout] | [INFO] [stdout] 127 | let sibV = sibiling.val; [INFO] [stdout] | ^^^^ help: convert the identifier to snake case: `sib_v` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `sibV` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:139:21 [INFO] [stdout] | [INFO] [stdout] 139 | let sibV = sibiling.val; [INFO] [stdout] | ^^^^ help: convert the identifier to snake case: `sib_v` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: call to `.clone()` on a reference in this situation does nothing [INFO] [stdout] --> src/crypto/merkle.rs:157:34 [INFO] [stdout] | [INFO] [stdout] 157 | let mut vec = Vec::from(proof.clone()); [INFO] [stdout] | ^^^^^^^^ help: remove this redundant call [INFO] [stdout] | [INFO] [stdout] = note: the type `[crypto::hash::H256]` does not implement `Clone`, so calling `clone` on `&[crypto::hash::H256]` copies the reference, which does not do anything and can be removed [INFO] [stdout] = note: `#[warn(noop_method_call)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `parentH` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:165:17 [INFO] [stdout] | [INFO] [stdout] 165 | let parentH = digest::digest(&digest::SHA256, &parent); [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `parent_h` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `parentH` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:176:17 [INFO] [stdout] | [INFO] [stdout] 176 | let parentH = digest::digest(&digest::SHA256, &parent); [INFO] [stdout] | ^^^^^^^ help: convert the identifier to snake case: `parent_h` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/network/message.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Message` [INFO] [stdout] 9 | pub enum Message { [INFO] [stdout] | ------- `Message` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/network/message.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Clone)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Message` [INFO] [stdout] 9 | pub enum Message { [INFO] [stdout] | ------- `Message` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/transaction.rs:11:10 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_Transaction` [INFO] [stdout] 12 | pub struct Transaction { [INFO] [stdout] | ----------- `Transaction` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Serialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Serialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Serialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/transaction.rs:11:21 [INFO] [stdout] | [INFO] [stdout] 11 | #[derive(Serialize, Deserialize, Debug, Default, Clone, PartialEq)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_Transaction` [INFO] [stdout] 12 | pub struct Transaction { [INFO] [stdout] | ----------- `Transaction` is not local [INFO] [stdout] | [INFO] [stdout] = note: the derive macro `Deserialize` defines the non-local `impl`, and may need to be changed [INFO] [stdout] = note: the derive macro `Deserialize` may come from an old version of the `serde_derive` crate, try updating your dependency with `cargo update -p serde_derive` [INFO] [stdout] = note: an `impl` is never scoped, even when it is nested inside an item, as it may impact type checking outside of that item, which can be the case if neither the trait or the self type are at the same nesting level as the `impl` [INFO] [stdout] = note: items in an anonymous const item (`const _: () = { ... }`) are treated as in the same scope as the anonymous const's declaration for the purpose of this lint [INFO] [stdout] = note: this warning originates in the derive macro `Deserialize` (in Nightly builds, run with -Z macro-backtrace for more info) [INFO] [stdout] [INFO] [stdout] [INFO] [stderr] Finished `dev` profile [unoptimized + debuginfo] target(s) in 36.18s [INFO] running `Command { std: "docker" "inspect" "ebc91f63c14b537de31668f913b855ec163dae0c0ea4024f76c1fe88bdf8cbbf", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "ebc91f63c14b537de31668f913b855ec163dae0c0ea4024f76c1fe88bdf8cbbf", kill_on_drop: false }` [INFO] [stdout] ebc91f63c14b537de31668f913b855ec163dae0c0ea4024f76c1fe88bdf8cbbf