Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
140 changes: 87 additions & 53 deletions Cargo.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ version = "0.2.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
error-chain = "0.11"
error-chain = "0.12"
polkadot-cli = { path = "polkadot/cli" }

[workspace]
Expand Down
2 changes: 1 addition & 1 deletion demo/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ctrlc = { git = "https://github.com/paritytech/rust-ctrlc.git" }
ed25519 = { path = "../../substrate/ed25519" }
env_logger = "0.4"
futures = "0.1.17"
error-chain = "0.11"
error-chain = "0.12"
hex-literal = "0.1"
log = "0.3"
tokio-core = "0.1.12"
Expand Down
2 changes: 1 addition & 1 deletion polkadot/api/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "0.1.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
error-chain = "0.11"
error-chain = "0.12"
polkadot-executor = { path = "../executor" }
polkadot-runtime = { path = "../runtime" }
polkadot-primitives = { path = "../primitives" }
Expand Down
2 changes: 1 addition & 1 deletion polkadot/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ description = "Polkadot node implementation in Rust."
[dependencies]
clap = { version = "2.27", features = ["yaml"] }
env_logger = "0.4"
error-chain = "0.11"
error-chain = "0.12"
log = "0.3"
atty = "0.2"
regex = "0.2"
Expand Down
2 changes: 1 addition & 1 deletion polkadot/consensus/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ futures = "0.1.17"
parking_lot = "0.4"
tokio-core = "0.1.12"
ed25519 = { path = "../../substrate/ed25519" }
error-chain = "0.11"
error-chain = "0.12"
log = "0.3"
exit-future = "0.1"
polkadot-api = { path = "../api" }
Expand Down
2 changes: 1 addition & 1 deletion polkadot/parachain/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ description = "Types and utilities for creating and working with parachains"
[dependencies]
substrate-codec = { path = "../../substrate/codec", default-features = false }
wasmi = { version = "0.1", optional = true }
error-chain = { version = "0.11", optional = true }
error-chain = { version = "0.12", optional = true }

[dev-dependencies]
tiny-keccak = "1.4"
Expand Down
2 changes: 1 addition & 1 deletion polkadot/service/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ authors = ["Parity Technologies <[email protected]>"]
futures = "0.1.17"
parking_lot = "0.4"
tokio-timer = "0.1.2"
error-chain = "0.11"
error-chain = "0.12"
lazy_static = "1.0"
log = "0.3"
slog = "^2"
Expand Down
2 changes: 1 addition & 1 deletion polkadot/transaction-pool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ authors = ["Parity Technologies <[email protected]>"]

[dependencies]
log = "0.3.0"
error-chain = "0.11"
error-chain = "0.12"
parking_lot = "0.4"
polkadot-api = { path = "../api" }
polkadot-primitives = { path = "../primitives" }
Expand Down
2 changes: 1 addition & 1 deletion substrate/bft/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ substrate-runtime-primitives = { path = "../runtime/primitives" }
ed25519 = { path = "../ed25519" }
tokio-timer = "0.1.2"
parking_lot = "0.4"
error-chain = "0.11"
error-chain = "0.12"
log = "0.3"

[dev-dependencies]
Expand Down
2 changes: 1 addition & 1 deletion substrate/client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "0.1.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
error-chain = "0.11"
error-chain = "0.12"
log = "0.3"
parking_lot = "0.4"
triehash = "0.1"
Expand Down
2 changes: 1 addition & 1 deletion substrate/executor/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "0.1.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
error-chain = "0.11"
error-chain = "0.12"
substrate-codec = { path = "../codec" }
substrate-runtime-io = { path = "../runtime-io" }
substrate-primitives = { path = "../primitives" }
Expand Down
2 changes: 1 addition & 1 deletion substrate/extrinsic-pool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "0.1.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
error-chain = "0.11"
error-chain = "0.12"
futures = "0.1"
log = "0.3"
parking_lot = "0.4"
Expand Down
2 changes: 1 addition & 1 deletion substrate/keystore/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ authors = ["Parity Technologies <[email protected]>"]
[dependencies]
ethcore-crypto = { git = "https://github.com/paritytech/parity.git", default_features = false }
ed25519 = { path = "../ed25519" }
error-chain = "0.11"
error-chain = "0.12"
hex = "0.3"
rand = "0.4"
serde_json = "1.0"
Expand Down
4 changes: 2 additions & 2 deletions substrate/keystore/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ impl EncryptedKey {

// two parts of derived key
// DK = [ DK[0..15] DK[16..31] ] = [derived_left_bits, derived_right_bits]
let (derived_left_bits, derived_right_bits) = crypto::derive_key_iterations(password, &salt, iterations);
let (derived_left_bits, derived_right_bits) = crypto::derive_key_iterations(password.as_bytes(), &salt, iterations);

// preallocated (on-stack in case of `Secret`) buffer to hold cipher
// length = length(plain) as we are using CTR-approach
Expand All @@ -108,7 +108,7 @@ impl EncryptedKey {

fn decrypt(&self, password: &str) -> Result<[u8; PKCS_LEN]> {
let (derived_left_bits, derived_right_bits) =
crypto::derive_key_iterations(password, &self.salt, self.iterations);
crypto::derive_key_iterations(password.as_bytes(), &self.salt, self.iterations);

let mac = crypto::derive_mac(&derived_right_bits, &self.ciphertext).keccak256();

Expand Down
2 changes: 1 addition & 1 deletion substrate/network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ authors = ["Parity Technologies <[email protected]>"]
log = "0.3"
rand = "0.3"
parking_lot = "0.4"
error-chain = "0.11"
error-chain = "0.12"
bitflags = "1.0"
serde = "1.0"
serde_derive = "1.0"
Expand Down
8 changes: 4 additions & 4 deletions substrate/network/src/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ use std::sync::Arc;
use std::io;
use std::time::Duration;
use futures::sync::{oneshot, mpsc};
use network::{NetworkProtocolHandler, NetworkContext, HostInfo, PeerId, ProtocolId,
use network::{NetworkProtocolHandler, NetworkContext, PeerId, ProtocolId,
NetworkConfiguration , NonReservedPeerMode, ErrorKind};
use network_devp2p::{NetworkService};
use core_io::{TimerToken};
Expand Down Expand Up @@ -175,9 +175,9 @@ impl<B: BlockT + 'static> Service<B> where B::Header: HeaderT<Number=u64> {
}

fn start(&self) {
match self.network.start().map_err(Into::into) {
match self.network.start().map_err(|e| e.0.into()) {
Err(ErrorKind::Io(ref e)) if e.kind() == io::ErrorKind::AddrInUse =>
warn!("Network port {:?} is already in use, make sure that another instance of Polkadot client is not running or change the port using the --port option.", self.network.config().listen_address.expect("Listen address is not set.")),
warn!("Network port is already in use, make sure that another instance of Polkadot client is not running or change the port using the --port option."),
Err(err) => warn!("Error starting network: {}", err),
_ => {},
};
Expand Down Expand Up @@ -257,7 +257,7 @@ impl<B: BlockT + 'static> ConsensusService<B> for Service<B> where B::Header: He
}

impl<B: BlockT + 'static> NetworkProtocolHandler for ProtocolHandler<B> where B::Header: HeaderT<Number=u64> {
fn initialize(&self, io: &NetworkContext, _host_info: &HostInfo) {
fn initialize(&self, io: &NetworkContext) {
io.register_timer(TICK_TOKEN, TICK_TIMEOUT)
.expect("Error registering sync timer");

Expand Down
2 changes: 1 addition & 1 deletion substrate/rpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "0.1.0"
authors = ["Parity Technologies <[email protected]>"]

[dependencies]
error-chain = "0.11"
error-chain = "0.12"
jsonrpc-core = { git="https://github.com/paritytech/jsonrpc.git" }
jsonrpc-macros = { git="https://github.com/paritytech/jsonrpc.git" }
jsonrpc-pubsub = { git="https://github.com/paritytech/jsonrpc.git" }
Expand Down