[INFO] cloning repository https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring [INFO] running `Command { std: "git" "-c" "credential.helper=" "-c" "credential.helper=/workspace/cargo-home/bin/git-credential-null" "clone" "--bare" "https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhsiangawang%2FPrinciples-of-Blockchain-2020Spring", kill_on_drop: false }` [INFO] [stderr] Cloning into bare repository '/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhsiangawang%2FPrinciples-of-Blockchain-2020Spring'... [INFO] running `Command { std: "git" "rev-parse" "HEAD", kill_on_drop: false }` [INFO] [stdout] 9952c4d0a9db21fd7b9da34694cc2230e097dedd [INFO] checking hsiangawang/Principles-of-Blockchain-2020Spring against master#a9e7b30487235621751cc628f170c0f15fb215c4 for pr-136539 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhsiangawang%2FPrinciples-of-Blockchain-2020Spring" "/workspace/builds/worker-4-tc1/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-4-tc1/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring on toolchain a9e7b30487235621751cc628f170c0f15fb215c4 [INFO] running `Command { std: CARGO_HOME="/workspace/cargo-home" RUSTUP_HOME="/workspace/rustup-home" "/workspace/cargo-home/bin/cargo" "+a9e7b30487235621751cc628f170c0f15fb215c4" "metadata" "--manifest-path" "Cargo.toml" "--no-deps", kill_on_drop: false }` [INFO] started tweaking git repo https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring [INFO] finished tweaking git repo https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring [INFO] tweaked toml for git repo https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring written to /workspace/builds/worker-4-tc1/source/Cargo.toml [INFO] crate git repo https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring 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" "+a9e7b30487235621751cc628f170c0f15fb215c4" "fetch" "--manifest-path" "Cargo.toml", kill_on_drop: false }` [INFO] [stderr] Downloading crates ... [INFO] [stderr] Downloaded ring v0.16.10 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-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:3959728d45483eb673ba100a951a6b9f5012970368db2a9e08e0ac9b67c8a5ad" "/opt/rustwide/cargo-home/bin/cargo" "+a9e7b30487235621751cc628f170c0f15fb215c4" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 9138ad07050a3af46f086e17e8ec7c4ca47a40e4257ebf376391fe5c1db9f18f [INFO] running `Command { std: "docker" "start" "-a" "9138ad07050a3af46f086e17e8ec7c4ca47a40e4257ebf376391fe5c1db9f18f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "9138ad07050a3af46f086e17e8ec7c4ca47a40e4257ebf376391fe5c1db9f18f", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "9138ad07050a3af46f086e17e8ec7c4ca47a40e4257ebf376391fe5c1db9f18f", kill_on_drop: false }` [INFO] [stdout] 9138ad07050a3af46f086e17e8ec7c4ca47a40e4257ebf376391fe5c1db9f18f [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-tc1/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-4-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:3959728d45483eb673ba100a951a6b9f5012970368db2a9e08e0ac9b67c8a5ad" "/opt/rustwide/cargo-home/bin/cargo" "+a9e7b30487235621751cc628f170c0f15fb215c4" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 40a942eec283d2be07ec5f1bb7fce3ff302345592dc90768d72fadc646acfb45 [INFO] running `Command { std: "docker" "start" "-a" "40a942eec283d2be07ec5f1bb7fce3ff302345592dc90768d72fadc646acfb45", kill_on_drop: false }` [INFO] [stderr] Compiling autocfg v0.1.6 [INFO] [stderr] Compiling libc v0.2.62 [INFO] [stderr] Checking cfg-if v0.1.10 [INFO] [stderr] Compiling proc-macro2 v1.0.5 [INFO] [stderr] Compiling unicode-xid v0.2.0 [INFO] [stderr] Checking lazy_static v1.4.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] Checking matches v0.1.8 [INFO] [stderr] Checking smallvec v0.6.10 [INFO] [stderr] Compiling log v0.4.8 [INFO] [stderr] Compiling arrayvec v0.4.12 [INFO] [stderr] Checking nodrop v0.1.14 [INFO] [stderr] Compiling serde v1.0.101 [INFO] [stderr] Compiling ryu v1.0.2 [INFO] [stderr] Checking unicode-bidi v0.3.4 [INFO] [stderr] Checking scopeguard v1.0.0 [INFO] [stderr] Checking crossbeam-utils v0.6.6 [INFO] [stderr] Compiling byteorder v1.3.2 [INFO] [stderr] Checking rand_core v0.3.1 [INFO] [stderr] Compiling bitflags v1.2.0 [INFO] [stderr] Compiling cc v1.0.45 [INFO] [stderr] Checking unicode-width v0.1.6 [INFO] [stderr] Compiling semver v0.9.0 [INFO] [stderr] Checking unicode-normalization v0.1.8 [INFO] [stderr] Checking percent-encoding v1.0.1 [INFO] [stderr] Checking slab v0.4.2 [INFO] [stderr] Compiling num-traits v0.2.8 [INFO] [stderr] Compiling num-integer v0.1.41 [INFO] [stderr] Compiling rand_pcg v0.1.2 [INFO] [stderr] Compiling rand_chacha v0.1.1 [INFO] [stderr] Compiling bincode v1.2.0 [INFO] [stderr] Compiling rand v0.6.5 [INFO] [stderr] Compiling rustc_version v0.2.3 [INFO] [stderr] Checking crossbeam-queue v0.1.2 [INFO] [stderr] Checking crossbeam-channel v0.3.9 [INFO] [stderr] Checking rand_xorshift v0.1.1 [INFO] [stderr] Checking rand_hc v0.1.0 [INFO] [stderr] Checking time v0.1.42 [INFO] [stderr] Checking net2 v0.2.33 [INFO] [stderr] Checking iovec v0.1.4 [INFO] [stderr] Checking term_size v0.3.1 [INFO] [stderr] Checking idna v0.1.5 [INFO] [stderr] Checking idna v0.2.0 [INFO] [stderr] Checking textwrap v0.11.0 [INFO] [stderr] Checking rand_os v0.1.3 [INFO] [stderr] Checking atty v0.2.13 [INFO] [stderr] Checking rand_isaac v0.1.1 [INFO] [stderr] Checking rand_jitter v0.1.4 [INFO] [stderr] Checking thread_local v0.3.6 [INFO] [stderr] Checking spin v0.5.2 [INFO] [stderr] Checking termcolor v0.3.6 [INFO] [stderr] Checking itoa v0.4.4 [INFO] [stderr] Compiling quote v1.0.2 [INFO] [stderr] Checking untrusted v0.7.0 [INFO] [stderr] Compiling memoffset v0.5.1 [INFO] [stderr] Checking mio v0.6.19 [INFO] [stderr] Checking ascii v0.8.7 [INFO] [stderr] Checking vec_map v0.8.1 [INFO] [stderr] Checking lazycell v1.2.1 [INFO] [stderr] Checking ansi_term v0.11.0 [INFO] [stderr] Checking strsim v0.8.0 [INFO] [stderr] Checking percent-encoding v2.1.0 [INFO] [stderr] Checking chunked_transfer v0.3.1 [INFO] [stderr] Checking hex v0.4.0 [INFO] [stderr] Checking url v1.7.2 [INFO] [stderr] Checking crossbeam-epoch v0.7.2 [INFO] [stderr] Compiling ring v0.16.10 [INFO] [stderr] Checking clap v2.33.0 [INFO] [stderr] Checking url v2.1.0 [INFO] [stderr] Checking mio-extras v2.0.5 [INFO] [stderr] Checking crossbeam-deque v0.7.1 [INFO] [stderr] Checking chrono v0.4.9 [INFO] [stderr] Checking crossbeam v0.7.2 [INFO] [stderr] Checking tiny_http v0.6.2 [INFO] [stderr] Checking stderrlog v0.4.1 [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 name: `test_utilities` [INFO] [stdout] --> src/block.rs:56:17 [INFO] [stdout] | [INFO] [stdout] 56 | #[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: `MerkleTree` [INFO] [stdout] --> src/block.rs:3:29 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::crypto::merkle::{MerkleTree}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `info` [INFO] [stdout] --> src/block.rs:5:11 [INFO] [stdout] | [INFO] [stdout] 5 | use log::{info}; [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.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/block.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/block.rs:14:10 [INFO] [stdout] | [INFO] [stdout] 14 | #[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/block.rs:14:21 [INFO] [stdout] | [INFO] [stdout] 14 | #[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/block.rs:23:10 [INFO] [stdout] | [INFO] [stdout] 23 | #[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/block.rs:23:21 [INFO] [stdout] | [INFO] [stdout] 23 | #[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 name: `test_utilities` [INFO] [stdout] --> src/blockchain.rs:145:17 [INFO] [stdout] | [INFO] [stdout] 145 | #[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: `std::convert::TryInto` [INFO] [stdout] --> src/blockchain.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::convert::TryInto; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `MerkleTree` [INFO] [stdout] --> src/blockchain.rs:4:29 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::crypto::merkle::{MerkleTree}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/blockchain.rs:6:26 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::transaction::{Transaction, SignedTransaction}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::crypto::hash::generate_random_hash` [INFO] [stdout] --> src/blockchain.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::crypto::hash::generate_random_hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::crypto::key_pair` [INFO] [stdout] --> src/blockchain.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | use crate::crypto::key_pair; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::collections::BTreeMap` [INFO] [stdout] --> src/blockchain.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | use std::collections::BTreeMap; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::transaction::sign` [INFO] [stdout] --> src/blockchain.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 13 | use crate::transaction::sign; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `KeyPair`, `Signature`, and `VerificationAlgorithm` [INFO] [stdout] --> src/blockchain.rs:14:23 [INFO] [stdout] | [INFO] [stdout] 14 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^ ^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `info` [INFO] [stdout] --> src/blockchain.rs:15:11 [INFO] [stdout] | [INFO] [stdout] 15 | use log::{info}; [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/blockchain.rs:17:10 [INFO] [stdout] | [INFO] [stdout] 17 | #[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/blockchain.rs:17:21 [INFO] [stdout] | [INFO] [stdout] 17 | #[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: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/blockchain.rs:112:11 [INFO] [stdout] | [INFO] [stdout] 112 | if(self.blocks_height[&block.hash()] > self.blocks_height[&self.tip]) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 112 - if(self.blocks_height[&block.hash()] > self.blocks_height[&self.tip]) [INFO] [stdout] 112 + if self.blocks_height[&block.hash()] > self.blocks_height[&self.tip] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/crypto/hash.rs:191:17 [INFO] [stdout] | [INFO] [stdout] 191 | #[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 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/hash.rs:14:25 [INFO] [stdout] | [INFO] [stdout] 14 | #[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:14:36 [INFO] [stdout] | [INFO] [stdout] 14 | #[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: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/merkle.rs:25:11 [INFO] [stdout] | [INFO] [stdout] 25 | if(level_hash.len() != 1 && (level_hash.len())%2 == 1) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 25 - if(level_hash.len() != 1 && (level_hash.len())%2 == 1) [INFO] [stdout] 25 + if level_hash.len() != 1 && (level_hash.len())%2 == 1 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/merkle.rs:32:15 [INFO] [stdout] | [INFO] [stdout] 32 | if(level_hash.len() % 2 != 0) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 32 - if(level_hash.len() % 2 != 0) [INFO] [stdout] 32 + if level_hash.len() % 2 != 0 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/crypto/merkle.rs:101:14 [INFO] [stdout] | [INFO] [stdout] 101 | for i in (0..proof_num) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 101 - for i in (0..proof_num) { [INFO] [stdout] 101 + for i in 0..proof_num { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/merkle.rs:102:11 [INFO] [stdout] | [INFO] [stdout] 102 | if(Idx % 2 == 0) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 102 - if(Idx % 2 == 0) [INFO] [stdout] 102 + if Idx % 2 == 0 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `Signature`, and `VerificationAlgorithm` [INFO] [stdout] --> src/miner.rs:17:23 [INFO] [stdout] | [INFO] [stdout] 17 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:172:16 [INFO] [stdout] | [INFO] [stdout] 172 | if (self.txs.lock().unwrap().is_empty()) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 172 - if (self.txs.lock().unwrap().is_empty()) { [INFO] [stdout] 172 + if self.txs.lock().unwrap().is_empty() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:189:15 [INFO] [stdout] | [INFO] [stdout] 189 | if(new_block.hash() <= difficulty) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 189 - if(new_block.hash() <= difficulty) [INFO] [stdout] 189 + if new_block.hash() <= difficulty [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/miner.rs:192:26 [INFO] [stdout] | [INFO] [stdout] 192 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 192 - for i in (0..size) { [INFO] [stdout] 192 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:193:24 [INFO] [stdout] | [INFO] [stdout] 193 | if (self.mempool.lock().unwrap().contains_key(&new_block.content.data[i].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 193 - if (self.mempool.lock().unwrap().contains_key(&new_block.content.data[i].hash())) { [INFO] [stdout] 193 + if self.mempool.lock().unwrap().contains_key(&new_block.content.data[i].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:202:28 [INFO] [stdout] | [INFO] [stdout] 202 | if (nonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 202 - if (nonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] 202 + if nonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:210:28 [INFO] [stdout] | [INFO] [stdout] 210 | if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 210 - if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 210 + if self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Hashable` [INFO] [stdout] --> src/network/message.rs:2:33 [INFO] [stdout] | [INFO] [stdout] 2 | use crate::crypto::hash::{H256, Hashable}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Content` and `Header` [INFO] [stdout] --> src/network/message.rs:3:27 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::block::{Block, Header, Content}; [INFO] [stdout] | ^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/network/message.rs:4:26 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::transaction::{Transaction, SignedTransaction}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/network/message.rs:6:10 [INFO] [stdout] | [INFO] [stdout] 6 | #[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:6:21 [INFO] [stdout] | [INFO] [stdout] 6 | #[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: unused imports: `Content` and `Header` [INFO] [stdout] --> src/network/worker.rs:8:27 [INFO] [stdout] | [INFO] [stdout] 8 | use crate::block::{Block, Header, Content}; [INFO] [stdout] | ^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize` [INFO] [stdout] --> src/network/worker.rs:12:13 [INFO] [stdout] | [INFO] [stdout] 12 | use serde::{Serialize,Deserialize}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/network/worker.rs:14:26 [INFO] [stdout] | [INFO] [stdout] 14 | use crate::transaction::{Transaction, SignedTransaction}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:94:30 [INFO] [stdout] | [INFO] [stdout] 94 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 94 - for i in (0..size) { [INFO] [stdout] 94 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:96:27 [INFO] [stdout] | [INFO] [stdout] 96 | if(!exist) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 96 - if(!exist) [INFO] [stdout] 96 + if !exist [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:112:30 [INFO] [stdout] | [INFO] [stdout] 112 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 112 - for i in (0..size) { [INFO] [stdout] 112 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:113:27 [INFO] [stdout] | [INFO] [stdout] 113 | if(!self.blockchain.lock().unwrap().hash_blocks.contains_key(&getblocks[i])) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 113 - if(!self.blockchain.lock().unwrap().hash_blocks.contains_key(&getblocks[i])) [INFO] [stdout] 113 + if !self.blockchain.lock().unwrap().hash_blocks.contains_key(&getblocks[i]) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:121:34 [INFO] [stdout] | [INFO] [stdout] 121 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 121 - for i in (0..size) { [INFO] [stdout] 121 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:139:30 [INFO] [stdout] | [INFO] [stdout] 139 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 139 - for i in (0..size) { [INFO] [stdout] 139 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:143:34 [INFO] [stdout] | [INFO] [stdout] 143 | for j in (0..signedTxs_size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 143 - for j in (0..signedTxs_size) { [INFO] [stdout] 143 + for j in 0..signedTxs_size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:149:31 [INFO] [stdout] | [INFO] [stdout] 149 | ... if(!verify(&blocks[i].content.data[j].Transaction, &blocks[i].content.data[j].public_key, &blocks[i].content.data[j].Signature)){ [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 149 - if(!verify(&blocks[i].content.data[j].Transaction, &blocks[i].content.data[j].public_key, &blocks[i].content.data[j].Signature)){ [INFO] [stdout] 149 + if !verify(&blocks[i].content.data[j].Transaction, &blocks[i].content.data[j].public_key, &blocks[i].content.data[j].Signature) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:153:36 [INFO] [stdout] | [INFO] [stdout] 153 | ... else if(hash_key_20bytes != blocks[i].content.data[j].sender_addr){ [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 153 - else if(hash_key_20bytes != blocks[i].content.data[j].sender_addr){ [INFO] [stdout] 153 + else if hash_key_20bytes != blocks[i].content.data[j].sender_addr { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:158:28 [INFO] [stdout] | [INFO] [stdout] 158 | if (!valid_block) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 158 - if (!valid_block) { [INFO] [stdout] 158 + if !valid_block { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:164:34 [INFO] [stdout] | [INFO] [stdout] 164 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 164 - for i in (0..size) { [INFO] [stdout] 164 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:166:38 [INFO] [stdout] | [INFO] [stdout] 166 | ... for j in (0..signedTxs_size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 166 - for j in (0..signedTxs_size) { [INFO] [stdout] 166 + for j in 0..signedTxs_size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:167:35 [INFO] [stdout] | [INFO] [stdout] 167 | ... if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 167 - if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] 167 + if self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:177:40 [INFO] [stdout] | [INFO] [stdout] 177 | ... if (accountNonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 177 - if (accountNonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] 177 + if accountNonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:184:40 [INFO] [stdout] | [INFO] [stdout] 184 | ... if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 184 - if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 184 + if self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:201:28 [INFO] [stdout] | [INFO] [stdout] 201 | if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 201 - if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].hash())) { [INFO] [stdout] 201 + if !self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:202:32 [INFO] [stdout] | [INFO] [stdout] 202 | ... if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].header.parent)) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 202 - if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].header.parent)) { [INFO] [stdout] 202 + if !self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].header.parent) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:212:36 [INFO] [stdout] | [INFO] [stdout] 212 | ... if (blocks[i].hash() <= diff) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 212 - if (blocks[i].hash() <= diff) { [INFO] [stdout] 212 + if blocks[i].hash() <= diff { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:253:40 [INFO] [stdout] | [INFO] [stdout] 253 | ... if (blocks[i].header.parent == prev_tip) { // condition 1. [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 253 - if (blocks[i].header.parent == prev_tip) { // condition 1. [INFO] [stdout] 253 + if blocks[i].header.parent == prev_tip { // condition 1. [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:262:44 [INFO] [stdout] | [INFO] [stdout] 262 | ... if (self.blockchain.lock().unwrap().tip() != blocks[i].hash()) { // condition 2 [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 262 - if (self.blockchain.lock().unwrap().tip() != blocks[i].hash()) { // condition 2 [INFO] [stdout] 262 + if self.blockchain.lock().unwrap().tip() != blocks[i].hash() { // condition 2 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:264:48 [INFO] [stdout] | [INFO] [stdout] 264 | ... if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 264 - if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 264 + if parent_state.accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:279:48 [INFO] [stdout] | [INFO] [stdout] 279 | ... if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 279 - if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 279 + if parent_state.accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:296:46 [INFO] [stdout] | [INFO] [stdout] 296 | ... for j in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 296 - for j in (0..size) { [INFO] [stdout] 296 + for j in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:297:43 [INFO] [stdout] | [INFO] [stdout] 297 | ... if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 297 - if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] 297 + if self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:307:32 [INFO] [stdout] | [INFO] [stdout] 307 | ... if (orphan_buffer.orphan_blocks.contains_key(&blocks[0].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 307 - if (orphan_buffer.orphan_blocks.contains_key(&blocks[0].hash())) { [INFO] [stdout] 307 + if orphan_buffer.orphan_blocks.contains_key(&blocks[0].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:311:42 [INFO] [stdout] | [INFO] [stdout] 311 | ... for j in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 311 - for j in (0..size) { [INFO] [stdout] 311 + for j in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:312:40 [INFO] [stdout] | [INFO] [stdout] 312 | ... if (self.mempool.lock().unwrap().contains_key(&blocks[0].content.data[j].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 312 - if (self.mempool.lock().unwrap().contains_key(&blocks[0].content.data[j].hash())) { [INFO] [stdout] 312 + if self.mempool.lock().unwrap().contains_key(&blocks[0].content.data[j].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:335:30 [INFO] [stdout] | [INFO] [stdout] 335 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 335 - for i in (0..size) { [INFO] [stdout] 335 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:337:27 [INFO] [stdout] | [INFO] [stdout] 337 | if(!exist) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 337 - if(!exist) [INFO] [stdout] 337 + if !exist [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:349:30 [INFO] [stdout] | [INFO] [stdout] 349 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 349 - for i in (0..size) { [INFO] [stdout] 349 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:350:27 [INFO] [stdout] | [INFO] [stdout] 350 | if(!self.mempool.lock().unwrap().contains_key(&get_trans[i])) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 350 - if(!self.mempool.lock().unwrap().contains_key(&get_trans[i])) [INFO] [stdout] 350 + if !self.mempool.lock().unwrap().contains_key(&get_trans[i]) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:358:34 [INFO] [stdout] | [INFO] [stdout] 358 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 358 - for i in (0..size) { [INFO] [stdout] 358 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:371:30 [INFO] [stdout] | [INFO] [stdout] 371 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 371 - for i in (0..size) { [INFO] [stdout] 371 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:372:27 [INFO] [stdout] | [INFO] [stdout] 372 | if(verify(&trans[i].Transaction, &trans[i].public_key, &trans[i].Signature)){ [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 372 - if(verify(&trans[i].Transaction, &trans[i].public_key, &trans[i].Signature)){ [INFO] [stdout] 372 + if verify(&trans[i].Transaction, &trans[i].public_key, &trans[i].Signature) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:386:24 [INFO] [stdout] | [INFO] [stdout] 386 | if (!verified) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 386 - if (!verified) { [INFO] [stdout] 386 + if !verified { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:388:34 [INFO] [stdout] | [INFO] [stdout] 388 | for j in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 388 - for j in (0..size) { [INFO] [stdout] 388 + for j in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/transaction.rs:64:17 [INFO] [stdout] | [INFO] [stdout] 64 | #[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 imports: `H256` and `Hashable` [INFO] [stdout] --> src/transaction.rs:3:27 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::crypto::hash::{H256, H160, Hashable}; [INFO] [stdout] | ^^^^ ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `info` [INFO] [stdout] --> src/transaction.rs:4:11 [INFO] [stdout] | [INFO] [stdout] 4 | use log::{info}; [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/transaction.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Default, 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/transaction.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Default, 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:15:10 [INFO] [stdout] | [INFO] [stdout] 15 | #[derive(Serialize, Deserialize, Debug, Default, 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/transaction.rs:15:21 [INFO] [stdout] | [INFO] [stdout] 15 | #[derive(Serialize, Deserialize, Debug, Default, 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: unused import: `Blockchain` [INFO] [stdout] --> src/TransGen.rs:3:25 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::blockchain::{Blockchain, State}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Block`, `Content`, and `Header` [INFO] [stdout] --> src/TransGen.rs:4:20 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::block::{Block, Content, Header}; [INFO] [stdout] | ^^^^^ ^^^^^^^ ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `MerkleTree` [INFO] [stdout] --> src/TransGen.rs:5:29 [INFO] [stdout] | [INFO] [stdout] 5 | use crate::crypto::merkle::{MerkleTree}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Receiver`, `Sender`, `TryRecvError`, and `unbounded` [INFO] [stdout] --> src/TransGen.rs:9:26 [INFO] [stdout] | [INFO] [stdout] 9 | use crossbeam::channel::{unbounded, Receiver, Sender, TryRecvError}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^ ^^^^^^ ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `Signature`, and `VerificationAlgorithm` [INFO] [stdout] --> src/TransGen.rs:17:23 [INFO] [stdout] | [INFO] [stdout] 17 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `H160` and `Hashable` [INFO] [stdout] --> src/main.rs:25:33 [INFO] [stdout] | [INFO] [stdout] 25 | use crate::crypto::hash::{H256, H160, Hashable}; [INFO] [stdout] | ^^^^ ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/main.rs:26:26 [INFO] [stdout] | [INFO] [stdout] 26 | use crate::transaction::{Transaction, SignedTransaction}; [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 name: `test_utilities` [INFO] [stdout] --> src/block.rs:56:17 [INFO] [stdout] | [INFO] [stdout] 56 | #[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: `info` [INFO] [stdout] --> src/block.rs:5:11 [INFO] [stdout] | [INFO] [stdout] 5 | use log::{info}; [INFO] [stdout] | ^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_imports)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/block.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/block.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/block.rs:14:10 [INFO] [stdout] | [INFO] [stdout] 14 | #[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/block.rs:14:21 [INFO] [stdout] | [INFO] [stdout] 14 | #[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/block.rs:23:10 [INFO] [stdout] | [INFO] [stdout] 23 | #[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/block.rs:23:21 [INFO] [stdout] | [INFO] [stdout] 23 | #[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 name: `test_utilities` [INFO] [stdout] --> src/blockchain.rs:145:17 [INFO] [stdout] | [INFO] [stdout] 145 | #[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: `std::convert::TryInto` [INFO] [stdout] --> src/blockchain.rs:3:5 [INFO] [stdout] | [INFO] [stdout] 3 | use std::convert::TryInto; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `MerkleTree` [INFO] [stdout] --> src/blockchain.rs:4:29 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::crypto::merkle::{MerkleTree}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/blockchain.rs:6:26 [INFO] [stdout] | [INFO] [stdout] 6 | use crate::transaction::{Transaction, SignedTransaction}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::crypto::hash::generate_random_hash` [INFO] [stdout] --> src/blockchain.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | use crate::crypto::hash::generate_random_hash; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::crypto::key_pair` [INFO] [stdout] --> src/blockchain.rs:8:5 [INFO] [stdout] | [INFO] [stdout] 8 | use crate::crypto::key_pair; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `std::collections::BTreeMap` [INFO] [stdout] --> src/blockchain.rs:10:5 [INFO] [stdout] | [INFO] [stdout] 10 | use std::collections::BTreeMap; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `crate::transaction::sign` [INFO] [stdout] --> src/blockchain.rs:13:5 [INFO] [stdout] | [INFO] [stdout] 13 | use crate::transaction::sign; [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `KeyPair`, `Signature`, and `VerificationAlgorithm` [INFO] [stdout] --> src/blockchain.rs:14:23 [INFO] [stdout] | [INFO] [stdout] 14 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^ ^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `info` [INFO] [stdout] --> src/blockchain.rs:15:11 [INFO] [stdout] | [INFO] [stdout] 15 | use log::{info}; [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/blockchain.rs:17:10 [INFO] [stdout] | [INFO] [stdout] 17 | #[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/blockchain.rs:17:21 [INFO] [stdout] | [INFO] [stdout] 17 | #[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: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/blockchain.rs:112:11 [INFO] [stdout] | [INFO] [stdout] 112 | if(self.blocks_height[&block.hash()] > self.blocks_height[&self.tip]) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 112 - if(self.blocks_height[&block.hash()] > self.blocks_height[&self.tip]) [INFO] [stdout] 112 + if self.blocks_height[&block.hash()] > self.blocks_height[&self.tip] [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/crypto/hash.rs:191:17 [INFO] [stdout] | [INFO] [stdout] 191 | #[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 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/hash.rs:14:25 [INFO] [stdout] | [INFO] [stdout] 14 | #[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:14:36 [INFO] [stdout] | [INFO] [stdout] 14 | #[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: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/merkle.rs:25:11 [INFO] [stdout] | [INFO] [stdout] 25 | if(level_hash.len() != 1 && (level_hash.len())%2 == 1) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 25 - if(level_hash.len() != 1 && (level_hash.len())%2 == 1) [INFO] [stdout] 25 + if level_hash.len() != 1 && (level_hash.len())%2 == 1 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/merkle.rs:32:15 [INFO] [stdout] | [INFO] [stdout] 32 | if(level_hash.len() % 2 != 0) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 32 - if(level_hash.len() % 2 != 0) [INFO] [stdout] 32 + if level_hash.len() % 2 != 0 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/crypto/merkle.rs:101:14 [INFO] [stdout] | [INFO] [stdout] 101 | for i in (0..proof_num) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 101 - for i in (0..proof_num) { [INFO] [stdout] 101 + for i in 0..proof_num { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/crypto/merkle.rs:102:11 [INFO] [stdout] | [INFO] [stdout] 102 | if(Idx % 2 == 0) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 102 - if(Idx % 2 == 0) [INFO] [stdout] 102 + if Idx % 2 == 0 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `Signature`, and `VerificationAlgorithm` [INFO] [stdout] --> src/miner.rs:17:23 [INFO] [stdout] | [INFO] [stdout] 17 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:172:16 [INFO] [stdout] | [INFO] [stdout] 172 | if (self.txs.lock().unwrap().is_empty()) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 172 - if (self.txs.lock().unwrap().is_empty()) { [INFO] [stdout] 172 + if self.txs.lock().unwrap().is_empty() { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:189:15 [INFO] [stdout] | [INFO] [stdout] 189 | if(new_block.hash() <= difficulty) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 189 - if(new_block.hash() <= difficulty) [INFO] [stdout] 189 + if new_block.hash() <= difficulty [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/miner.rs:192:26 [INFO] [stdout] | [INFO] [stdout] 192 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 192 - for i in (0..size) { [INFO] [stdout] 192 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:193:24 [INFO] [stdout] | [INFO] [stdout] 193 | if (self.mempool.lock().unwrap().contains_key(&new_block.content.data[i].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 193 - if (self.mempool.lock().unwrap().contains_key(&new_block.content.data[i].hash())) { [INFO] [stdout] 193 + if self.mempool.lock().unwrap().contains_key(&new_block.content.data[i].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:202:28 [INFO] [stdout] | [INFO] [stdout] 202 | if (nonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 202 - if (nonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] 202 + if nonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/miner.rs:210:28 [INFO] [stdout] | [INFO] [stdout] 210 | if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 210 - if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 210 + if self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Hashable` [INFO] [stdout] --> src/network/message.rs:2:33 [INFO] [stdout] | [INFO] [stdout] 2 | use crate::crypto::hash::{H256, Hashable}; [INFO] [stdout] | ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Content` and `Header` [INFO] [stdout] --> src/network/message.rs:3:27 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::block::{Block, Header, Content}; [INFO] [stdout] | ^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/network/message.rs:4:26 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::transaction::{Transaction, SignedTransaction}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/network/message.rs:6:10 [INFO] [stdout] | [INFO] [stdout] 6 | #[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:6:21 [INFO] [stdout] | [INFO] [stdout] 6 | #[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: unused imports: `Content` and `Header` [INFO] [stdout] --> src/network/worker.rs:8:27 [INFO] [stdout] | [INFO] [stdout] 8 | use crate::block::{Block, Header, Content}; [INFO] [stdout] | ^^^^^^ ^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Deserialize` and `Serialize` [INFO] [stdout] --> src/network/worker.rs:12:13 [INFO] [stdout] | [INFO] [stdout] 12 | use serde::{Serialize,Deserialize}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/network/worker.rs:14:26 [INFO] [stdout] | [INFO] [stdout] 14 | use crate::transaction::{Transaction, SignedTransaction}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:94:30 [INFO] [stdout] | [INFO] [stdout] 94 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 94 - for i in (0..size) { [INFO] [stdout] 94 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:96:27 [INFO] [stdout] | [INFO] [stdout] 96 | if(!exist) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 96 - if(!exist) [INFO] [stdout] 96 + if !exist [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:112:30 [INFO] [stdout] | [INFO] [stdout] 112 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 112 - for i in (0..size) { [INFO] [stdout] 112 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:113:27 [INFO] [stdout] | [INFO] [stdout] 113 | if(!self.blockchain.lock().unwrap().hash_blocks.contains_key(&getblocks[i])) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 113 - if(!self.blockchain.lock().unwrap().hash_blocks.contains_key(&getblocks[i])) [INFO] [stdout] 113 + if !self.blockchain.lock().unwrap().hash_blocks.contains_key(&getblocks[i]) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:121:34 [INFO] [stdout] | [INFO] [stdout] 121 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 121 - for i in (0..size) { [INFO] [stdout] 121 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:139:30 [INFO] [stdout] | [INFO] [stdout] 139 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 139 - for i in (0..size) { [INFO] [stdout] 139 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:143:34 [INFO] [stdout] | [INFO] [stdout] 143 | for j in (0..signedTxs_size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 143 - for j in (0..signedTxs_size) { [INFO] [stdout] 143 + for j in 0..signedTxs_size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:149:31 [INFO] [stdout] | [INFO] [stdout] 149 | ... if(!verify(&blocks[i].content.data[j].Transaction, &blocks[i].content.data[j].public_key, &blocks[i].content.data[j].Signature)){ [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 149 - if(!verify(&blocks[i].content.data[j].Transaction, &blocks[i].content.data[j].public_key, &blocks[i].content.data[j].Signature)){ [INFO] [stdout] 149 + if !verify(&blocks[i].content.data[j].Transaction, &blocks[i].content.data[j].public_key, &blocks[i].content.data[j].Signature) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:153:36 [INFO] [stdout] | [INFO] [stdout] 153 | ... else if(hash_key_20bytes != blocks[i].content.data[j].sender_addr){ [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 153 - else if(hash_key_20bytes != blocks[i].content.data[j].sender_addr){ [INFO] [stdout] 153 + else if hash_key_20bytes != blocks[i].content.data[j].sender_addr { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:158:28 [INFO] [stdout] | [INFO] [stdout] 158 | if (!valid_block) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 158 - if (!valid_block) { [INFO] [stdout] 158 + if !valid_block { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:164:34 [INFO] [stdout] | [INFO] [stdout] 164 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 164 - for i in (0..size) { [INFO] [stdout] 164 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:166:38 [INFO] [stdout] | [INFO] [stdout] 166 | ... for j in (0..signedTxs_size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 166 - for j in (0..signedTxs_size) { [INFO] [stdout] 166 + for j in 0..signedTxs_size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:167:35 [INFO] [stdout] | [INFO] [stdout] 167 | ... if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 167 - if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] 167 + if self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:177:40 [INFO] [stdout] | [INFO] [stdout] 177 | ... if (accountNonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 177 - if (accountNonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1) { [INFO] [stdout] 177 + if accountNonce != self.states.lock().unwrap().accountMaping[&sender_addr].0 + 1 { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:184:40 [INFO] [stdout] | [INFO] [stdout] 184 | ... if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 184 - if (self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 184 + if self.states.lock().unwrap().accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:201:28 [INFO] [stdout] | [INFO] [stdout] 201 | if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 201 - if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].hash())) { [INFO] [stdout] 201 + if !self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:202:32 [INFO] [stdout] | [INFO] [stdout] 202 | ... if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].header.parent)) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 202 - if (!self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].header.parent)) { [INFO] [stdout] 202 + if !self.blockchain.lock().unwrap().hash_blocks.contains_key(&blocks[i].header.parent) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:212:36 [INFO] [stdout] | [INFO] [stdout] 212 | ... if (blocks[i].hash() <= diff) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 212 - if (blocks[i].hash() <= diff) { [INFO] [stdout] 212 + if blocks[i].hash() <= diff { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:253:40 [INFO] [stdout] | [INFO] [stdout] 253 | ... if (blocks[i].header.parent == prev_tip) { // condition 1. [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 253 - if (blocks[i].header.parent == prev_tip) { // condition 1. [INFO] [stdout] 253 + if blocks[i].header.parent == prev_tip { // condition 1. [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:262:44 [INFO] [stdout] | [INFO] [stdout] 262 | ... if (self.blockchain.lock().unwrap().tip() != blocks[i].hash()) { // condition 2 [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 262 - if (self.blockchain.lock().unwrap().tip() != blocks[i].hash()) { // condition 2 [INFO] [stdout] 262 + if self.blockchain.lock().unwrap().tip() != blocks[i].hash() { // condition 2 [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:264:48 [INFO] [stdout] | [INFO] [stdout] 264 | ... if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 264 - if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 264 + if parent_state.accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:279:48 [INFO] [stdout] | [INFO] [stdout] 279 | ... if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 279 - if (parent_state.accountMaping[&sender_addr].1 >= trans_money) { [INFO] [stdout] 279 + if parent_state.accountMaping[&sender_addr].1 >= trans_money { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:296:46 [INFO] [stdout] | [INFO] [stdout] 296 | ... for j in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 296 - for j in (0..size) { [INFO] [stdout] 296 + for j in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:297:43 [INFO] [stdout] | [INFO] [stdout] 297 | ... if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 297 - if (self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash())) { [INFO] [stdout] 297 + if self.mempool.lock().unwrap().contains_key(&blocks[i].content.data[j].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:307:32 [INFO] [stdout] | [INFO] [stdout] 307 | ... if (orphan_buffer.orphan_blocks.contains_key(&blocks[0].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 307 - if (orphan_buffer.orphan_blocks.contains_key(&blocks[0].hash())) { [INFO] [stdout] 307 + if orphan_buffer.orphan_blocks.contains_key(&blocks[0].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:311:42 [INFO] [stdout] | [INFO] [stdout] 311 | ... for j in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 311 - for j in (0..size) { [INFO] [stdout] 311 + for j in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:312:40 [INFO] [stdout] | [INFO] [stdout] 312 | ... if (self.mempool.lock().unwrap().contains_key(&blocks[0].content.data[j].hash())) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 312 - if (self.mempool.lock().unwrap().contains_key(&blocks[0].content.data[j].hash())) { [INFO] [stdout] 312 + if self.mempool.lock().unwrap().contains_key(&blocks[0].content.data[j].hash()) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:335:30 [INFO] [stdout] | [INFO] [stdout] 335 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 335 - for i in (0..size) { [INFO] [stdout] 335 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:337:27 [INFO] [stdout] | [INFO] [stdout] 337 | if(!exist) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 337 - if(!exist) [INFO] [stdout] 337 + if !exist [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:349:30 [INFO] [stdout] | [INFO] [stdout] 349 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 349 - for i in (0..size) { [INFO] [stdout] 349 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:350:27 [INFO] [stdout] | [INFO] [stdout] 350 | if(!self.mempool.lock().unwrap().contains_key(&get_trans[i])) [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 350 - if(!self.mempool.lock().unwrap().contains_key(&get_trans[i])) [INFO] [stdout] 350 + if !self.mempool.lock().unwrap().contains_key(&get_trans[i]) [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:358:34 [INFO] [stdout] | [INFO] [stdout] 358 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 358 - for i in (0..size) { [INFO] [stdout] 358 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:371:30 [INFO] [stdout] | [INFO] [stdout] 371 | for i in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 371 - for i in (0..size) { [INFO] [stdout] 371 + for i in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:372:27 [INFO] [stdout] | [INFO] [stdout] 372 | if(verify(&trans[i].Transaction, &trans[i].public_key, &trans[i].Signature)){ [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 372 - if(verify(&trans[i].Transaction, &trans[i].public_key, &trans[i].Signature)){ [INFO] [stdout] 372 + if verify(&trans[i].Transaction, &trans[i].public_key, &trans[i].Signature) { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `if` condition [INFO] [stdout] --> src/network/worker.rs:386:24 [INFO] [stdout] | [INFO] [stdout] 386 | if (!verified) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 386 - if (!verified) { [INFO] [stdout] 386 + if !verified { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unnecessary parentheses around `for` iterator expression [INFO] [stdout] --> src/network/worker.rs:388:34 [INFO] [stdout] | [INFO] [stdout] 388 | for j in (0..size) { [INFO] [stdout] | ^ ^ [INFO] [stdout] | [INFO] [stdout] help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] 388 - for j in (0..size) { [INFO] [stdout] 388 + for j in 0..size { [INFO] [stdout] | [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition name: `test_utilities` [INFO] [stdout] --> src/transaction.rs:64:17 [INFO] [stdout] | [INFO] [stdout] 64 | #[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 imports: `H256` and `Hashable` [INFO] [stdout] --> src/transaction.rs:3:27 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::crypto::hash::{H256, H160, Hashable}; [INFO] [stdout] | ^^^^ ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `info` [INFO] [stdout] --> src/transaction.rs:4:11 [INFO] [stdout] | [INFO] [stdout] 4 | use log::{info}; [INFO] [stdout] | ^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unexpected `cfg` condition value: `cargo-clippy` [INFO] [stdout] --> src/transaction.rs:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Default, 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/transaction.rs:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Default, 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:15:10 [INFO] [stdout] | [INFO] [stdout] 15 | #[derive(Serialize, Deserialize, Debug, Default, 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/transaction.rs:15:21 [INFO] [stdout] | [INFO] [stdout] 15 | #[derive(Serialize, Deserialize, Debug, Default, 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: unused import: `Blockchain` [INFO] [stdout] --> src/TransGen.rs:3:25 [INFO] [stdout] | [INFO] [stdout] 3 | use crate::blockchain::{Blockchain, State}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Block`, `Content`, and `Header` [INFO] [stdout] --> src/TransGen.rs:4:20 [INFO] [stdout] | [INFO] [stdout] 4 | use crate::block::{Block, Content, Header}; [INFO] [stdout] | ^^^^^ ^^^^^^^ ^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `MerkleTree` [INFO] [stdout] --> src/TransGen.rs:5:29 [INFO] [stdout] | [INFO] [stdout] 5 | use crate::crypto::merkle::{MerkleTree}; [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Receiver`, `Sender`, `TryRecvError`, and `unbounded` [INFO] [stdout] --> src/TransGen.rs:9:26 [INFO] [stdout] | [INFO] [stdout] 9 | use crossbeam::channel::{unbounded, Receiver, Sender, TryRecvError}; [INFO] [stdout] | ^^^^^^^^^ ^^^^^^^^ ^^^^^^ ^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `Signature`, and `VerificationAlgorithm` [INFO] [stdout] --> src/TransGen.rs:17:23 [INFO] [stdout] | [INFO] [stdout] 17 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [INFO] [stdout] | ^^^^^^^^^^^^^^ ^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `H160` and `Hashable` [INFO] [stdout] --> src/main.rs:25:33 [INFO] [stdout] | [INFO] [stdout] 25 | use crate::crypto::hash::{H256, H160, Hashable}; [INFO] [stdout] | ^^^^ ^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `Transaction` [INFO] [stdout] --> src/main.rs:26:26 [INFO] [stdout] | [INFO] [stdout] 26 | use crate::transaction::{Transaction, SignedTransaction}; [INFO] [stdout] | ^^^^^^^^^^^ [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused import: `KeyPair` [INFO] [stdout] --> src/transaction.rs:2:50 [INFO] [stdout] | [INFO] [stdout] 2 | use ring::signature::{Ed25519KeyPair, Signature, KeyPair, VerificationAlgorithm, EdDSAParameters}; [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] error[E0560]: struct `transaction::Transaction` has no field named `Input` [INFO] [stdout] --> src/block.rs:77:39 [INFO] [stdout] | [INFO] [stdout] 77 | let transaction = Transaction{Input: In, Output: Out}; [INFO] [stdout] | ^^^^^ `transaction::Transaction` does not have this field [INFO] [stdout] | [INFO] [stdout] = note: available fields are: `recipAddress`, `val`, `accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0560]: struct `transaction::Transaction` has no field named `Output` [INFO] [stdout] --> src/block.rs:77:50 [INFO] [stdout] | [INFO] [stdout] 77 | let transaction = Transaction{Input: In, Output: Out}; [INFO] [stdout] | ^^^^^^ `transaction::Transaction` does not have this field [INFO] [stdout] | [INFO] [stdout] = note: available fields are: `recipAddress`, `val`, `accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:24:13 [INFO] [stdout] | [INFO] [stdout] 24 | let mut accountMaping : HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `Recipient` [INFO] [stdout] --> src/blockchain.rs:73:13 [INFO] [stdout] | [INFO] [stdout] 73 | let Recipient : H160 =(&raw_bytes_recipient).into(); [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_Recipient` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `val` [INFO] [stdout] --> src/blockchain.rs:74:13 [INFO] [stdout] | [INFO] [stdout] 74 | let val : u32 = rng.gen(); [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_val` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `accountNonce` [INFO] [stdout] --> src/blockchain.rs:75:17 [INFO] [stdout] | [INFO] [stdout] 75 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:45:13 [INFO] [stdout] | [INFO] [stdout] 45 | let mut chainState: HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:46:13 [INFO] [stdout] | [INFO] [stdout] 46 | let mut tip : H256; [INFO] [stdout] | ----^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:75:13 [INFO] [stdout] | [INFO] [stdout] 75 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ----^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:79:13 [INFO] [stdout] | [INFO] [stdout] 79 | let mut SignedTransactions: Vec = Vec::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> src/block.rs:83:35 [INFO] [stdout] | [INFO] [stdout] 83 | let content = Content{data : transactions}; [INFO] [stdout] | ^^^^^^^^^^^^ expected `Vec`, found `Vec` [INFO] [stdout] | [INFO] [stdout] = note: expected struct `Vec` [INFO] [stdout] found struct `Vec` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `concatenation` is never read [INFO] [stdout] --> src/crypto/merkle.rs:99:13 [INFO] [stdout] | [INFO] [stdout] 99 | let mut concatenation = [cur_hash.as_ref(), cur_hash.as_ref()].concat(); [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `leaf_size` [INFO] [stdout] --> src/crypto/merkle.rs:94:72 [INFO] [stdout] | [INFO] [stdout] 94 | 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: variable `timestamp` is assigned to, but never used [INFO] [stdout] --> src/miner.rs:136:17 [INFO] [stdout] | [INFO] [stdout] 136 | let timestamp; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_timestamp` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `timestamp` is never read [INFO] [stdout] --> src/miner.rs:139:26 [INFO] [stdout] | [INFO] [stdout] 139 | Ok(n) => timestamp = n.as_millis(), [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `signed_transaction` [INFO] [stdout] --> src/miner.rs:159:17 [INFO] [stdout] | [INFO] [stdout] 159 | ... let signed_transaction = SignedTransaction{Transaction: transaction, Signature : signature.as_ref().to_vec(), public_key : key.publ... [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_signed_transaction` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `txs_perBlock` [INFO] [stdout] --> src/miner.rs:163:17 [INFO] [stdout] | [INFO] [stdout] 163 | let txs_perBlock = 1; [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_txs_perBlock` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/miner.rs:151:17 [INFO] [stdout] | [INFO] [stdout] 151 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ----^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `orphan_size` [INFO] [stdout] --> src/network/worker.rs:138:29 [INFO] [stdout] | [INFO] [stdout] 138 | let mut orphan_size = orphan_buffer.orphan_blocks.len(); [INFO] [stdout] | ^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_orphan_size` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `accountNonce` [INFO] [stdout] --> src/network/worker.rs:260:45 [INFO] [stdout] | [INFO] [stdout] 260 | ... let accountNonce = blocks[i].content.data[0].Transaction.accountNonce; [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:68:13 [INFO] [stdout] | [INFO] [stdout] 68 | let mut orphan_blocks: HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:138:25 [INFO] [stdout] | [INFO] [stdout] 138 | let mut orphan_size = orphan_buffer.orphan_blocks.len(); [INFO] [stdout] | ----^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:215:41 [INFO] [stdout] | [INFO] [stdout] 215 | ... let mut timestamp = blocks[i].header.timestamp; [INFO] [stdout] | ----^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:216:41 [INFO] [stdout] | [INFO] [stdout] 216 | ... let mut cur_time; [INFO] [stdout] | ----^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:222:41 [INFO] [stdout] | [INFO] [stdout] 222 | ... let mut delay = cur_time - timestamp; [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `v` [INFO] [stdout] --> src/transaction.rs:58:12 [INFO] [stdout] | [INFO] [stdout] 58 | Ok(v) => return true, [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_v` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `e` [INFO] [stdout] --> src/transaction.rs:59:13 [INFO] [stdout] | [INFO] [stdout] 59 | Err(e) => return false, [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_e` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `nonce` [INFO] [stdout] --> src/TransGen.rs:56:13 [INFO] [stdout] | [INFO] [stdout] 56 | let nonce : u32 = rng.gen(); [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_nonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `Recipient` [INFO] [stdout] --> src/TransGen.rs:60:13 [INFO] [stdout] | [INFO] [stdout] 60 | let Recipient : H160 =(&raw_bytes_recipient).into(); [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_Recipient` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `hash_key_20bytes` [INFO] [stdout] --> src/TransGen.rs:64:13 [INFO] [stdout] | [INFO] [stdout] 64 | let hash_key_20bytes : H160 = hash_key.as_ref()[12..=31].into(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_hash_key_20bytes` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/main.rs:88:9 [INFO] [stdout] | [INFO] [stdout] 88 | let mut hash_signedTxs: HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/main.rs:90:9 [INFO] [stdout] | [INFO] [stdout] 90 | let mut signedTxs: VecDeque = VecDeque::new(); [INFO] [stdout] | ----^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: field `txs` is never read [INFO] [stdout] --> src/network/worker.rs:31:5 [INFO] [stdout] | [INFO] [stdout] 24 | pub struct Context { [INFO] [stdout] | ------- field in this struct [INFO] [stdout] ... [INFO] [stdout] 31 | txs : Arc>>, [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)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: module `TransGen` should have a snake case name [INFO] [stdout] --> src/main.rs:12:9 [INFO] [stdout] | [INFO] [stdout] 12 | pub mod TransGen; [INFO] [stdout] | ^^^^^^^^ help: convert the identifier to snake case: `trans_gen` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(non_snake_case)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `hash_signedTxs` should have a snake case name [INFO] [stdout] --> src/main.rs:88:13 [INFO] [stdout] | [INFO] [stdout] 88 | let mut hash_signedTxs: HashMap = HashMap::new(); [INFO] [stdout] | ^^^^^^^^^^^^^^ help: convert the identifier to snake case: `hash_signed_txs` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `signedTxs` should have a snake case name [INFO] [stdout] --> src/main.rs:90:13 [INFO] [stdout] | [INFO] [stdout] 90 | let mut signedTxs: VecDeque = VecDeque::new(); [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case: `signed_txs` [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: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_Block` [INFO] [stdout] 9 | 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: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_Block` [INFO] [stdout] 9 | 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: non-local `impl` definition, `impl` blocks should be written at the same level as their item [INFO] [stdout] --> src/block.rs:14:10 [INFO] [stdout] | [INFO] [stdout] 14 | #[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_Header` [INFO] [stdout] 15 | 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:14:21 [INFO] [stdout] | [INFO] [stdout] 14 | #[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_Header` [INFO] [stdout] 15 | 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:23:10 [INFO] [stdout] | [INFO] [stdout] 23 | #[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_Content` [INFO] [stdout] 24 | pub struct Content { [INFO] [stdout] | ------- `Content` 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:23:21 [INFO] [stdout] | [INFO] [stdout] 23 | #[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_Content` [INFO] [stdout] 24 | pub struct Content { [INFO] [stdout] | ------- `Content` 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 `accountMaping` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:19:9 [INFO] [stdout] | [INFO] [stdout] 19 | pub accountMaping : HashMap, // accountAddress (accountNonce, balance) [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `account_maping` [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:17:10 [INFO] [stdout] | [INFO] [stdout] 17 | #[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_State` [INFO] [stdout] 18 | pub struct State { [INFO] [stdout] | ----- `State` 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:17:21 [INFO] [stdout] | [INFO] [stdout] 17 | #[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_State` [INFO] [stdout] 18 | pub struct State { [INFO] [stdout] | ----- `State` 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 `accountMaping` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:24:17 [INFO] [stdout] | [INFO] [stdout] 24 | let mut accountMaping : HashMap = HashMap::new(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `account_maping` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `chainState` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:36:9 [INFO] [stdout] | [INFO] [stdout] 36 | pub chainState : HashMap, [INFO] [stdout] | ^^^^^^^^^^ help: convert the identifier to snake case: `chain_state` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `chainState` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:45:17 [INFO] [stdout] | [INFO] [stdout] 45 | let mut chainState: HashMap = HashMap::new(); [INFO] [stdout] | ^^^^^^^^^^ help: convert the identifier to snake case: `chain_state` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `Parent` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:61:13 [INFO] [stdout] | [INFO] [stdout] 61 | let Parent =(&raw_bytes_parent).into(); [INFO] [stdout] | ^^^^^^ help: convert the identifier to snake case: `parent` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `random_genesisRoot` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:63:13 [INFO] [stdout] | [INFO] [stdout] 63 | let random_genesisRoot: Vec = (0..32).map(|_| 5).collect(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `random_genesis_root` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `Recipient` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:73:13 [INFO] [stdout] | [INFO] [stdout] 73 | let Recipient : H160 =(&raw_bytes_recipient).into(); [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case: `recipient` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `accountNonce` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:75:17 [INFO] [stdout] | [INFO] [stdout] 75 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `account_nonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `SignedTransactions` should have a snake case name [INFO] [stdout] --> src/blockchain.rs:79:17 [INFO] [stdout] | [INFO] [stdout] 79 | let mut SignedTransactions: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `signed_transactions` [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 , I add "pub" in front of [u8;32] [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 , I add "pub" in front of [u8;32] [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/hash.rs:14:25 [INFO] [stdout] | [INFO] [stdout] 14 | #[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_H160` [INFO] [stdout] 15 | pub struct H160([u8; 20]); [INFO] [stdout] | ---- `H160` 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:14:36 [INFO] [stdout] | [INFO] [stdout] 14 | #[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_H160` [INFO] [stdout] 15 | pub struct H160([u8; 20]); [INFO] [stdout] | ---- `H160` 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 `Root` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:7:5 [INFO] [stdout] | [INFO] [stdout] 7 | Root: H256, [INFO] [stdout] | ^^^^ help: convert the identifier to snake case: `root` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `Idx` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:73:17 [INFO] [stdout] | [INFO] [stdout] 73 | let mut Idx = index; [INFO] [stdout] | ^^^ help: convert the identifier to snake case (notice the capitalization): `idx` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `Idx` should have a snake case name [INFO] [stdout] --> src/crypto/merkle.rs:98:13 [INFO] [stdout] | [INFO] [stdout] 98 | let mut Idx = index; [INFO] [stdout] | ^^^ help: convert the identifier to snake case (notice the capitalization): `idx` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: function `Hardcoded` should have a snake case name [INFO] [stdout] --> src/crypto/key_pair.rs:11:9 [INFO] [stdout] | [INFO] [stdout] 11 | pub fn Hardcoded() -> Ed25519KeyPair { [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case: `hardcoded` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `Recipient` should have a snake case name [INFO] [stdout] --> src/miner.rs:149:17 [INFO] [stdout] | [INFO] [stdout] 149 | let Recipient : H160 =(&raw_bytes_recipient).into(); [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case: `recipient` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `accountNonce` should have a snake case name [INFO] [stdout] --> src/miner.rs:151:21 [INFO] [stdout] | [INFO] [stdout] 151 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `account_nonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `SignedTransactions` should have a snake case name [INFO] [stdout] --> src/miner.rs:162:21 [INFO] [stdout] | [INFO] [stdout] 162 | let mut SignedTransactions: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `signed_transactions` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `txs_perBlock` should have a snake case name [INFO] [stdout] --> src/miner.rs:163:17 [INFO] [stdout] | [INFO] [stdout] 163 | let txs_perBlock = 1; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `txs_per_block` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `new_blockHash` should have a snake case name [INFO] [stdout] --> src/miner.rs:226:29 [INFO] [stdout] | [INFO] [stdout] 226 | let mut new_blockHash: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `new_block_hash` [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:6:10 [INFO] [stdout] | [INFO] [stdout] 6 | #[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] 7 | 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:6:21 [INFO] [stdout] | [INFO] [stdout] 6 | #[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] 7 | 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: variable `signedTxs_size` should have a snake case name [INFO] [stdout] --> src/network/worker.rs:142:29 [INFO] [stdout] | [INFO] [stdout] 142 | let signedTxs_size = blocks[i].content.data.len(); [INFO] [stdout] | ^^^^^^^^^^^^^^ help: convert the identifier to snake case: `signed_txs_size` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `signedTxs_size` should have a snake case name [INFO] [stdout] --> src/network/worker.rs:165:33 [INFO] [stdout] | [INFO] [stdout] 165 | ... let signedTxs_size = blocks[i].content.data.len(); [INFO] [stdout] | ^^^^^^^^^^^^^^ help: convert the identifier to snake case: `signed_txs_size` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `accountNonce` should have a snake case name [INFO] [stdout] --> src/network/worker.rs:172:41 [INFO] [stdout] | [INFO] [stdout] 172 | ... let accountNonce = blocks[i].content.data[j].Transaction.accountNonce; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `account_nonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `accountNonce` should have a snake case name [INFO] [stdout] --> src/network/worker.rs:260:45 [INFO] [stdout] | [INFO] [stdout] 260 | ... let accountNonce = blocks[i].content.data[0].Transaction.accountNonce; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `account_nonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `new_blockHash` should have a snake case name [INFO] [stdout] --> src/network/worker.rs:301:45 [INFO] [stdout] | [INFO] [stdout] 301 | ... let mut new_blockHash: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `new_block_hash` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `new_blockHash_orphan` should have a snake case name [INFO] [stdout] --> src/network/worker.rs:317:41 [INFO] [stdout] | [INFO] [stdout] 317 | ... let mut new_blockHash_orphan: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^^ help: convert the identifier to snake case: `new_block_hash_orphan` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `new_transHash` should have a snake case name [INFO] [stdout] --> src/network/worker.rs:369:29 [INFO] [stdout] | [INFO] [stdout] 369 | let mut new_transHash: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `new_trans_hash` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `recipAddress` should have a snake case name [INFO] [stdout] --> src/transaction.rs:10:9 [INFO] [stdout] | [INFO] [stdout] 10 | pub recipAddress : H160, [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `recip_address` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `accountNonce` should have a snake case name [INFO] [stdout] --> src/transaction.rs:12:9 [INFO] [stdout] | [INFO] [stdout] 12 | pub accountNonce : u16, [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `account_nonce` [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:8:10 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Default, Clone)] [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] 9 | 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:8:21 [INFO] [stdout] | [INFO] [stdout] 8 | #[derive(Serialize, Deserialize, Debug, Default, Clone)] [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] 9 | 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: structure field `Transaction` should have a snake case name [INFO] [stdout] --> src/transaction.rs:17:9 [INFO] [stdout] | [INFO] [stdout] 17 | pub Transaction : Transaction, [INFO] [stdout] | ^^^^^^^^^^^ help: convert the identifier to snake case: `transaction` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: structure field `Signature` should have a snake case name [INFO] [stdout] --> src/transaction.rs:19:9 [INFO] [stdout] | [INFO] [stdout] 19 | pub Signature : Vec, // by function into_vec [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case (notice the capitalization): `signature` [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:15:10 [INFO] [stdout] | [INFO] [stdout] 15 | #[derive(Serialize, Deserialize, Debug, Default, Clone)] [INFO] [stdout] | ^-------- [INFO] [stdout] | | [INFO] [stdout] | `Serialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_SERIALIZE_FOR_SignedTransaction` [INFO] [stdout] 16 | pub struct SignedTransaction { [INFO] [stdout] | ----------------- `SignedTransaction` 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:15:21 [INFO] [stdout] | [INFO] [stdout] 15 | #[derive(Serialize, Deserialize, Debug, Default, Clone)] [INFO] [stdout] | ^---------- [INFO] [stdout] | | [INFO] [stdout] | `Deserialize` is not local [INFO] [stdout] | move the `impl` block outside of this constant `_IMPL_DESERIALIZE_FOR_SignedTransaction` [INFO] [stdout] 16 | pub struct SignedTransaction { [INFO] [stdout] | ----------------- `SignedTransaction` 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 `Recipient` should have a snake case name [INFO] [stdout] --> src/TransGen.rs:60:13 [INFO] [stdout] | [INFO] [stdout] 60 | let Recipient : H160 =(&raw_bytes_recipient).into(); [INFO] [stdout] | ^^^^^^^^^ help: convert the identifier to snake case: `recipient` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `accountNonce` should have a snake case name [INFO] [stdout] --> src/TransGen.rs:61:17 [INFO] [stdout] | [INFO] [stdout] 61 | let mut accountNonce : u16 = 1; [INFO] [stdout] | ^^^^^^^^^^^^ help: convert the identifier to snake case: `account_nonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `senderAddress` should have a snake case name [INFO] [stdout] --> src/TransGen.rs:68:13 [INFO] [stdout] | [INFO] [stdout] 68 | let senderAddress : H160 = [70, 8, 220, 215, 80, 53, 152, 74, 136, 126, 87, 62, 230, 168, 2, 10, 237, 58, 51, 50].into(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `sender_address` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `recverAddress` should have a snake case name [INFO] [stdout] --> src/TransGen.rs:69:13 [INFO] [stdout] | [INFO] [stdout] 69 | let recverAddress : H160 = [140, 160, 200, 230, 190, 145, 185, 70, 100, 30, 122, 218, 43, 212, 90, 238, 170, 7, 122, 128].into(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `recver_address` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable `new_blockHash` should have a snake case name [INFO] [stdout] --> src/TransGen.rs:91:21 [INFO] [stdout] | [INFO] [stdout] 91 | let mut new_blockHash: Vec = Vec::new(); [INFO] [stdout] | ^^^^^^^^^^^^^ help: convert the identifier to snake case: `new_block_hash` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0560]: struct `transaction::Transaction` has no field named `Input` [INFO] [stdout] --> src/transaction.rs:79:39 [INFO] [stdout] | [INFO] [stdout] 79 | let transaction = Transaction{Input: In, Output: Out}; [INFO] [stdout] | ^^^^^ `transaction::Transaction` does not have this field [INFO] [stdout] | [INFO] [stdout] = note: available fields are: `recipAddress`, `val`, `accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0560]: struct `transaction::Transaction` has no field named `Output` [INFO] [stdout] --> src/transaction.rs:79:50 [INFO] [stdout] | [INFO] [stdout] 79 | let transaction = Transaction{Input: In, Output: Out}; [INFO] [stdout] | ^^^^^^ `transaction::Transaction` does not have this field [INFO] [stdout] | [INFO] [stdout] = note: available fields are: `recipAddress`, `val`, `accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: arguments to this function are incorrect [INFO] [stdout] --> src/transaction.rs:89:17 [INFO] [stdout] | [INFO] [stdout] 89 | assert!(verify(&t, &(key.public_key()), &signature)); [INFO] [stdout] | ^^^^^^ [INFO] [stdout] | [INFO] [stdout] note: expected `&Vec`, found `&&PublicKey` [INFO] [stdout] --> src/transaction.rs:89:28 [INFO] [stdout] | [INFO] [stdout] 89 | assert!(verify(&t, &(key.public_key()), &signature)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ [INFO] [stdout] = note: expected reference `&Vec` [INFO] [stdout] found reference `&&ring::ec::curve25519::ed25519::signing::PublicKey` [INFO] [stdout] note: expected `&Vec`, found `&Signature` [INFO] [stdout] --> src/transaction.rs:89:49 [INFO] [stdout] | [INFO] [stdout] 89 | assert!(verify(&t, &(key.public_key()), &signature)); [INFO] [stdout] | ^^^^^^^^^^ [INFO] [stdout] = note: expected reference `&Vec` [INFO] [stdout] found reference `&Signature` [INFO] [stdout] note: function defined here [INFO] [stdout] --> src/transaction.rs:50:8 [INFO] [stdout] | [INFO] [stdout] 50 | pub fn verify(t: &Transaction, public_key: &Vec, signature: &Vec) -> bool { [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: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:24:13 [INFO] [stdout] | [INFO] [stdout] 24 | let mut accountMaping : HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_mut)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `Recipient` [INFO] [stdout] --> src/blockchain.rs:73:13 [INFO] [stdout] | [INFO] [stdout] 73 | let Recipient : H160 =(&raw_bytes_recipient).into(); [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_Recipient` [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_variables)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `val` [INFO] [stdout] --> src/blockchain.rs:74:13 [INFO] [stdout] | [INFO] [stdout] 74 | let val : u32 = rng.gen(); [INFO] [stdout] | ^^^ help: if this is intentional, prefix it with an underscore: `_val` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `accountNonce` [INFO] [stdout] --> src/blockchain.rs:75:17 [INFO] [stdout] | [INFO] [stdout] 75 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:45:13 [INFO] [stdout] | [INFO] [stdout] 45 | let mut chainState: HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:46:13 [INFO] [stdout] | [INFO] [stdout] 46 | let mut tip : H256; [INFO] [stdout] | ----^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:75:13 [INFO] [stdout] | [INFO] [stdout] 75 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ----^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/blockchain.rs:79:13 [INFO] [stdout] | [INFO] [stdout] 79 | let mut SignedTransactions: Vec = Vec::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `concatenation` is never read [INFO] [stdout] --> src/crypto/merkle.rs:99:13 [INFO] [stdout] | [INFO] [stdout] 99 | let mut concatenation = [cur_hash.as_ref(), cur_hash.as_ref()].concat(); [INFO] [stdout] | ^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] = note: `#[warn(unused_assignments)]` on by default [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `leaf_size` [INFO] [stdout] --> src/crypto/merkle.rs:94:72 [INFO] [stdout] | [INFO] [stdout] 94 | 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: variable `timestamp` is assigned to, but never used [INFO] [stdout] --> src/miner.rs:136:17 [INFO] [stdout] | [INFO] [stdout] 136 | let timestamp; [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: consider using `_timestamp` instead [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: value assigned to `timestamp` is never read [INFO] [stdout] --> src/miner.rs:139:26 [INFO] [stdout] | [INFO] [stdout] 139 | Ok(n) => timestamp = n.as_millis(), [INFO] [stdout] | ^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = help: maybe it is overwritten before being read? [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `signed_transaction` [INFO] [stdout] --> src/miner.rs:159:17 [INFO] [stdout] | [INFO] [stdout] 159 | ... let signed_transaction = SignedTransaction{Transaction: transaction, Signature : signature.as_ref().to_vec(), public_key : key.publ... [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_signed_transaction` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `txs_perBlock` [INFO] [stdout] --> src/miner.rs:163:17 [INFO] [stdout] | [INFO] [stdout] 163 | let txs_perBlock = 1; [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_txs_perBlock` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/miner.rs:151:17 [INFO] [stdout] | [INFO] [stdout] 151 | let mut accountNonce : u16 = 0; [INFO] [stdout] | ----^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `orphan_size` [INFO] [stdout] --> src/network/worker.rs:138:29 [INFO] [stdout] | [INFO] [stdout] 138 | let mut orphan_size = orphan_buffer.orphan_blocks.len(); [INFO] [stdout] | ^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_orphan_size` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `accountNonce` [INFO] [stdout] --> src/network/worker.rs:260:45 [INFO] [stdout] | [INFO] [stdout] 260 | ... let accountNonce = blocks[i].content.data[0].Transaction.accountNonce; [INFO] [stdout] | ^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_accountNonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:68:13 [INFO] [stdout] | [INFO] [stdout] 68 | let mut orphan_blocks: HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:138:25 [INFO] [stdout] | [INFO] [stdout] 138 | let mut orphan_size = orphan_buffer.orphan_blocks.len(); [INFO] [stdout] | ----^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:215:41 [INFO] [stdout] | [INFO] [stdout] 215 | ... let mut timestamp = blocks[i].header.timestamp; [INFO] [stdout] | ----^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:216:41 [INFO] [stdout] | [INFO] [stdout] 216 | ... let mut cur_time; [INFO] [stdout] | ----^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/network/worker.rs:222:41 [INFO] [stdout] | [INFO] [stdout] 222 | ... let mut delay = cur_time - timestamp; [INFO] [stdout] | ----^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `v` [INFO] [stdout] --> src/transaction.rs:58:12 [INFO] [stdout] | [INFO] [stdout] 58 | Ok(v) => return true, [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_v` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `e` [INFO] [stdout] --> src/transaction.rs:59:13 [INFO] [stdout] | [INFO] [stdout] 59 | Err(e) => return false, [INFO] [stdout] | ^ help: if this is intentional, prefix it with an underscore: `_e` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `nonce` [INFO] [stdout] --> src/TransGen.rs:56:13 [INFO] [stdout] | [INFO] [stdout] 56 | let nonce : u32 = rng.gen(); [INFO] [stdout] | ^^^^^ help: if this is intentional, prefix it with an underscore: `_nonce` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `Recipient` [INFO] [stdout] --> src/TransGen.rs:60:13 [INFO] [stdout] | [INFO] [stdout] 60 | let Recipient : H160 =(&raw_bytes_recipient).into(); [INFO] [stdout] | ^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_Recipient` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused variable: `hash_key_20bytes` [INFO] [stdout] --> src/TransGen.rs:64:13 [INFO] [stdout] | [INFO] [stdout] 64 | let hash_key_20bytes : H160 = hash_key.as_ref()[12..=31].into(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_hash_key_20bytes` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/main.rs:88:9 [INFO] [stdout] | [INFO] [stdout] 88 | let mut hash_signedTxs: HashMap = HashMap::new(); [INFO] [stdout] | ----^^^^^^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: variable does not need to be mutable [INFO] [stdout] --> src/main.rs:90:9 [INFO] [stdout] | [INFO] [stdout] 90 | let mut signedTxs: VecDeque = VecDeque::new(); [INFO] [stdout] | ----^^^^^^^^^ [INFO] [stdout] | | [INFO] [stdout] | help: remove this `mut` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] Some errors have detailed explanations: E0308, E0560. [INFO] [stdout] [INFO] [stdout] For more information about an error, try `rustc --explain E0308`. [INFO] [stdout] [INFO] [stderr] error: could not compile `bitcoin` (bin "bitcoin" test) due to 6 previous errors; 127 warnings emitted [INFO] running `Command { std: "docker" "inspect" "40a942eec283d2be07ec5f1bb7fce3ff302345592dc90768d72fadc646acfb45", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "40a942eec283d2be07ec5f1bb7fce3ff302345592dc90768d72fadc646acfb45", kill_on_drop: false }` [INFO] [stdout] 40a942eec283d2be07ec5f1bb7fce3ff302345592dc90768d72fadc646acfb45