[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 try#8e3afc79c11f48cb3acd1be5b3b7de98fe3f93a8 for pr-82565 [INFO] running `Command { std: "git" "clone" "/workspace/cache/git-repos/https%3A%2F%2Fgithub.com%2Fhsiangawang%2FPrinciples-of-Blockchain-2020Spring" "/workspace/builds/worker-5/source", kill_on_drop: false }` [INFO] [stderr] Cloning into '/workspace/builds/worker-5/source'... [INFO] [stderr] done. [INFO] validating manifest of git repo https://github.com/hsiangawang/Principles-of-Blockchain-2020Spring on toolchain 8e3afc79c11f48cb3acd1be5b3b7de98fe3f93a8 [INFO] running `Command { std: "/workspace/cargo-home/bin/cargo" "+8e3afc79c11f48cb3acd1be5b3b7de98fe3f93a8" "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-5/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: "/workspace/cargo-home/bin/cargo" "+8e3afc79c11f48cb3acd1be5b3b7de98fe3f93a8" "fetch" "--locked" "--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-5/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5/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" "rustops/crates-build-env@sha256:f2f6bcd4b43ebee4e173f653a26493129bdb64017c85f916b780ca7fbdbaa79d" "/opt/rustwide/cargo-home/bin/cargo" "+8e3afc79c11f48cb3acd1be5b3b7de98fe3f93a8" "metadata" "--no-deps" "--format-version=1", kill_on_drop: false }` [INFO] [stdout] 79025617e6b345c798c61d7d77bebdf1e9fb183486ffccc1edb34a28801d4e05 [INFO] [stderr] WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap. [INFO] running `Command { std: "docker" "start" "-a" "79025617e6b345c798c61d7d77bebdf1e9fb183486ffccc1edb34a28801d4e05", kill_on_drop: false }` [INFO] running `Command { std: "docker" "inspect" "79025617e6b345c798c61d7d77bebdf1e9fb183486ffccc1edb34a28801d4e05", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "79025617e6b345c798c61d7d77bebdf1e9fb183486ffccc1edb34a28801d4e05", kill_on_drop: false }` [INFO] [stdout] 79025617e6b345c798c61d7d77bebdf1e9fb183486ffccc1edb34a28801d4e05 [INFO] running `Command { std: "docker" "create" "-v" "/var/lib/crater-agent-workspace/builds/worker-5/target:/opt/rustwide/target:rw,Z" "-v" "/var/lib/crater-agent-workspace/builds/worker-5/source:/opt/rustwide/workdir:ro,Z" "-v" "/var/lib/crater-agent-workspace/cargo-home:/opt/rustwide/cargo-home:ro,Z" "-v" "/var/lib/crater-agent-workspace/rustup-home:/opt/rustwide/rustup-home:ro,Z" "-e" "SOURCE_DIR=/opt/rustwide/workdir" "-e" "CARGO_TARGET_DIR=/opt/rustwide/target" "-e" "CARGO_INCREMENTAL=0" "-e" "RUST_BACKTRACE=full" "-e" "RUSTFLAGS=--cap-lints=forbid" "-e" "CARGO_HOME=/opt/rustwide/cargo-home" "-e" "RUSTUP_HOME=/opt/rustwide/rustup-home" "-w" "/opt/rustwide/workdir" "-m" "1610612736" "--user" "0:0" "--network" "none" "rustops/crates-build-env@sha256:f2f6bcd4b43ebee4e173f653a26493129bdb64017c85f916b780ca7fbdbaa79d" "/opt/rustwide/cargo-home/bin/cargo" "+8e3afc79c11f48cb3acd1be5b3b7de98fe3f93a8" "check" "--frozen" "--all" "--all-targets" "--message-format=json", kill_on_drop: false }` [INFO] [stdout] 2bb92759d5feb54005d918e526482bc48034b273a844b2953c29f74fe86a5d3a [INFO] [stderr] WARNING: Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap. [INFO] running `Command { std: "docker" "start" "-a" "2bb92759d5feb54005d918e526482bc48034b273a844b2953c29f74fe86a5d3a", kill_on_drop: false }` [INFO] [stderr] Checking cfg-if v0.1.10 [INFO] [stderr] Compiling proc-macro2 v1.0.5 [INFO] [stderr] Checking rand_core v0.4.2 [INFO] [stderr] Compiling semver-parser v0.7.0 [INFO] [stderr] Compiling log v0.4.8 [INFO] [stderr] Checking smallvec v0.6.10 [INFO] [stderr] Compiling arrayvec v0.4.12 [INFO] [stderr] Checking nodrop v0.1.14 [INFO] [stderr] Checking scopeguard v1.0.0 [INFO] [stderr] Compiling bitflags v1.2.0 [INFO] [stderr] Compiling byteorder v1.3.2 [INFO] [stderr] Checking slab v0.4.2 [INFO] [stderr] Checking untrusted v0.7.0 [INFO] [stderr] Checking percent-encoding v2.1.0 [INFO] [stderr] Checking hex v0.4.0 [INFO] [stderr] Compiling bincode v1.2.0 [INFO] [stderr] Checking thread_local v0.3.6 [INFO] [stderr] Compiling ring v0.16.10 [INFO] [stderr] Checking crossbeam-utils v0.6.6 [INFO] [stderr] Checking term_size v0.3.1 [INFO] [stderr] Checking iovec v0.1.4 [INFO] [stderr] Checking net2 v0.2.33 [INFO] [stderr] Checking rand_core v0.3.1 [INFO] [stderr] Checking rand_os v0.1.3 [INFO] [stderr] Checking rand_pcg v0.1.2 [INFO] [stderr] Checking rand_jitter v0.1.4 [INFO] [stderr] Compiling semver v0.9.0 [INFO] [stderr] Checking chrono v0.4.9 [INFO] [stderr] Checking textwrap v0.11.0 [INFO] [stderr] Checking rand_xorshift v0.1.1 [INFO] [stderr] Checking rand_chacha v0.1.1 [INFO] [stderr] Checking rand_isaac v0.1.1 [INFO] [stderr] Checking rand_hc v0.1.0 [INFO] [stderr] Checking unicode-normalization v0.1.8 [INFO] [stderr] Checking crossbeam-queue v0.1.2 [INFO] [stderr] Checking crossbeam-channel v0.3.9 [INFO] [stderr] Compiling rustc_version v0.2.3 [INFO] [stderr] Checking rand v0.6.5 [INFO] [stderr] Checking mio v0.6.19 [INFO] [stderr] Checking clap v2.33.0 [INFO] [stderr] Compiling memoffset v0.5.1 [INFO] [stderr] Compiling quote v1.0.2 [INFO] [stderr] Checking stderrlog v0.4.1 [INFO] [stderr] Checking mio-extras v2.0.5 [INFO] [stderr] Checking crossbeam-epoch v0.7.2 [INFO] [stderr] Checking idna v0.1.5 [INFO] [stderr] Checking idna v0.2.0 [INFO] [stderr] Compiling syn v1.0.5 [INFO] [stderr] Checking crossbeam-deque v0.7.1 [INFO] [stderr] Checking crossbeam v0.7.2 [INFO] [stderr] Checking url v2.1.0 [INFO] [stderr] Checking url v1.7.2 [INFO] [stderr] Checking tiny_http v0.6.2 [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 v1.0.101 [INFO] [stderr] Checking serde_json v1.0.44 [INFO] [stderr] Checking bitcoin v0.1.0 (/opt/rustwide/workdir) [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: 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`, `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: 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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^ help: remove these parentheses [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `Signature`, `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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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`, `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: unused imports: `Content`, `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`, `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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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`, `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: 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`, `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`, `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`, `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`, `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: `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: 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`, `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: 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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_parens)]` on by default [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^ help: remove these parentheses [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] warning: unused imports: `Ed25519KeyPair`, `EdDSAParameters`, `Signature`, `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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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`, `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: unused imports: `Content`, `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`, `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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^^^ help: remove these parentheses [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] | ^^^^^^^^^ help: remove these parentheses [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`, `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: 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`, `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`, `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`, `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`, `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] 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: 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] 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:13 [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: value assigned to `concatenation` is never read [INFO] [stdout] --> src/crypto/merkle.rs:99:9 [INFO] [stdout] | [INFO] [stdout] 99 | let mut concatenation = [cur_hash.as_ref(), cur_hash.as_ref()].concat(); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^ [INFO] [stdout] | [INFO] [stdout] = note: `#[warn(unused_assignments)]` on by default [INFO] [stdout] = help: maybe it is overwritten before being read? [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: unused variable: `orphan_size` [INFO] [stdout] --> src/network/worker.rs:138:25 [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: 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] = note: `#[warn(unused_mut)]` on by default [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: 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] [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 struct `SignedTransaction`, found struct `transaction::Transaction` [INFO] [stdout] | [INFO] [stdout] = note: expected struct `Vec` [INFO] [stdout] found struct `Vec` [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: 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: 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: 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: 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: 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: 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: 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: 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] warning: 143 warnings emitted [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]: mismatched types [INFO] [stdout] --> src/transaction.rs:89:28 [INFO] [stdout] | [INFO] [stdout] 89 | assert!(verify(&t, &(key.public_key()), &signature)); [INFO] [stdout] | ^^^^^^^^^^^^^^^^^^^ expected struct `Vec`, found `&ring::ec::curve25519::ed25519::signing::PublicKey` [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&Vec` [INFO] [stdout] found reference `&&ring::ec::curve25519::ed25519::signing::PublicKey` [INFO] [stdout] [INFO] [stdout] [INFO] [stdout] error[E0308]: mismatched types [INFO] [stdout] --> src/transaction.rs:89:49 [INFO] [stdout] | [INFO] [stdout] 89 | assert!(verify(&t, &(key.public_key()), &signature)); [INFO] [stdout] | ^^^^^^^^^^ expected struct `Vec`, found struct `Signature` [INFO] [stdout] | [INFO] [stdout] = note: expected reference `&Vec` [INFO] [stdout] found reference `&Signature` [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: aborting due to 7 previous errors; 75 warnings emitted [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` [INFO] [stderr] [INFO] [stderr] To learn more, run the command again with --verbose. [INFO] running `Command { std: "docker" "inspect" "2bb92759d5feb54005d918e526482bc48034b273a844b2953c29f74fe86a5d3a", kill_on_drop: false }` [INFO] running `Command { std: "docker" "rm" "-f" "2bb92759d5feb54005d918e526482bc48034b273a844b2953c29f74fe86a5d3a", kill_on_drop: false }` [INFO] [stdout] 2bb92759d5feb54005d918e526482bc48034b273a844b2953c29f74fe86a5d3a