Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies #1532

Merged
merged 1 commit into from
Oct 23, 2019
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
313 changes: 122 additions & 191 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 @@ -38,7 +38,7 @@ members = [
actix = "0.8.2"
lazy_static = "1.4.0"
log = "0.4.6"
rand = "0.6"
rand = "0.7"
serde_json = "1.0.0"
reqwest = "0.9"
futures = "0.1.25"
Expand Down
2 changes: 1 addition & 1 deletion async-utils/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ authors = ["Near Inc <hello@nearprotocol.com>"]
edition = "2018"

[dependencies]
futures03 = { package = "futures-preview", version = "0.3.0-alpha.16", features = ["compat", "async-await", "nightly"] }
futures03 = { package = "futures-preview", version = "0.3.0-alpha.19", features = ["compat", "async-await"] }
tokio = "0.1.15"
5 changes: 2 additions & 3 deletions chain/chain/src/test_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ use near_primitives::transaction::{
TransferAction,
};
use near_primitives::types::{
AccountId, Balance, BlockIndex, EpochId, MerkleHash, Nonce, ShardId, StateRoot,
ValidatorStake,
AccountId, Balance, BlockIndex, EpochId, MerkleHash, Nonce, ShardId, StateRoot, ValidatorStake,
};
use near_primitives::views::QueryResponse;
use near_store::test_utils::create_test_store;
Expand Down Expand Up @@ -179,7 +178,7 @@ impl KeyValueRuntime {
}
let prev_block_header = self
.get_block_header(prev_hash)?
.ok_or(format!("Missing block {} when computing the epoch", prev_hash))?;
.ok_or_else(|| format!("Missing block {} when computing the epoch", prev_hash))?;
Ok(prev_block_header.inner.height)
}

Expand Down
9 changes: 2 additions & 7 deletions chain/chunks/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,15 @@ edition = "2018"

[dependencies]
actix = "0.8.1"
typed-arena = "1.4.1"
futures = "0.1.25"
tokio = "0.1"
rand = "0.6"
rand_xorshift = "0.1"
rand = "0.7"
chrono = "0.4.6"
log = "0.4"
borsh = "0.2.2"
borsh = "0.2.7"
serde = "1.0"
serde_derive = "1.0"
elapsed = "0.1"
protobuf = "2.4"
reed-solomon-erasure = "3.1.1"
crossbeam = "0.3.0"
cached = "0.9.0"

near-crypto = { path = "../../core/crypto" }
Expand Down
4 changes: 2 additions & 2 deletions chain/client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ authors = ["Near Inc <hello@nearprotocol.com>"]
edition = "2018"

[dependencies]
ansi_term = "0.11.0"
ansi_term = "0.12"
actix = "0.8.1"
futures = "0.1"
chrono = { version = "0.4.4", features = ["serde"] }
kvdb = "0.1"
log = "0.4"
rand = "0.6.5"
rand = "0.7"
serde = { version = "1.0", features = ["derive"] }
serde_derive = "1.0"
serde_json = "1.0"
Expand Down
13 changes: 10 additions & 3 deletions chain/client/tests/chunks_management.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,29 @@ use near_client::{ClientActor, GetBlock, ViewClientActor};
use near_network::{NetworkClientMessages, NetworkRequests, NetworkResponses, PeerInfo};
use near_primitives::block::BlockHeader;
use near_primitives::hash::CryptoHash;
use near_primitives::test_utils::heavy_test;
use near_primitives::test_utils::init_integration_logger;
use near_primitives::transaction::SignedTransaction;

#[test]
fn chunks_produced_and_distributed_all_in_all_shards() {
chunks_produced_and_distributed_common(1);
heavy_test(|| {
chunks_produced_and_distributed_common(1);
});
}

#[test]
fn chunks_produced_and_distributed_2_vals_per_shard() {
chunks_produced_and_distributed_common(2);
heavy_test(|| {
chunks_produced_and_distributed_common(2);
});
}

#[test]
fn chunks_produced_and_distributed_one_val_per_shard() {
chunks_produced_and_distributed_common(4);
heavy_test(|| {
chunks_produced_and_distributed_common(4);
});
}

/// Runs block producing client and stops after network mock received seven blocks
Expand Down
4 changes: 2 additions & 2 deletions chain/epoch_manager/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ edition = "2018"


[dependencies]
rand = "0.6.5"
protocol_defining_rand = { package = "rand", version = "0.6.5" }
log = "0.4"
borsh = "0.2.2"
borsh = "0.2.7"
serde = "1.0"
serde_derive = "1.0"
serde_json = "1.0"
Expand Down
15 changes: 7 additions & 8 deletions chain/epoch_manager/src/proposals.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ use std::collections::btree_map::Entry;
use std::collections::{BTreeMap, HashMap, HashSet};
use std::iter;

use rand::seq::SliceRandom;
use rand::{rngs::StdRng, SeedableRng};

use near_primitives::types::{AccountId, Balance, ValidatorId, ValidatorStake};

use crate::types::{EpochConfig, EpochError, EpochInfo, RngSeed};
Expand Down Expand Up @@ -118,10 +115,13 @@ pub fn proposals_to_epoch_info(
if dup_proposals.len() < num_seats as usize {
return Err(EpochError::SelectedSeatsMismatch(dup_proposals.len() as u64, num_seats));
}

// Shuffle duplicate proposals.
let mut rng: StdRng = SeedableRng::from_seed(rng_seed);
dup_proposals.shuffle(&mut rng);
{
use protocol_defining_rand::seq::SliceRandom;
use protocol_defining_rand::{rngs::StdRng, SeedableRng};
// Shuffle duplicate proposals.
let mut rng: StdRng = SeedableRng::from_seed(rng_seed);
dup_proposals.shuffle(&mut rng);
}

// Block producers are first `num_block_producers` proposals.
let block_producers = dup_proposals[..epoch_config.num_block_producers].to_vec();
Expand Down Expand Up @@ -236,5 +236,4 @@ mod tests {
)
);
}

}
6 changes: 3 additions & 3 deletions chain/jsonrpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ authors = ["Near Inc <hello@nearprotocol.com>"]
edition = "2018"

[dependencies]
ansi_term = "0.11.0"
ansi_term = "0.12"
actix = "0.8.1"
actix-web = "1.0.0-rc"
actix-cors = "0.1"
base64 = "0.10.0"
bytes = "0.4.11"
futures = "0.1"
futures03 = { package = "futures-preview", version = "0.3.0-alpha.18", features = ["compat", "async-await", "nightly"] }
futures03 = { package = "futures-preview", version = "0.3.0-alpha.19", features = ["compat", "async-await"] }
chrono = { version = "0.4.4", features = ["serde"] }
lazy_static = "1.4"
log = "0.4"
Expand All @@ -21,7 +21,7 @@ serde_derive = "1.0"
serde_json = "1.0"
serde = { version = "1.0", features = ["derive"] }
tokio = "0.1.15"
uuid = { version = "~0.6", features = ["v4"] }
uuid = { version = "~0.8", features = ["v4"] }

borsh = "0.2.7"

Expand Down
2 changes: 1 addition & 1 deletion chain/jsonrpc/client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ futures = "0.1"
serde_derive = "1.0"
serde_json = "1.0"
serde = "1.0"
uuid = { version = "~0.6", features = ["v4"] }
uuid = { version = "~0.8", features = ["v4"] }

near-primitives = { path = "../../../core/primitives" }
2 changes: 1 addition & 1 deletion chain/jsonrpc/client/src/message.rs
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ impl Message {
jsonrpc: Version,
method,
params,
id: Value::String(Uuid::new_v4().hyphenated().to_string()),
id: Value::String(Uuid::new_v4().to_hyphenated().to_string()),
})
}
/// Create a top-level error (without an ID).
Expand Down
2 changes: 1 addition & 1 deletion chain/network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ futures = "0.1"
chrono = { version = "0.4.4", features = ["serde"] }
serde = "1.0"
serde_derive = "1.0"
rand = "0.6.5"
rand = "0.7"
reed-solomon-erasure = "3.1.1"
byteorder = "1.2"
lazy_static = "1.4"
Expand Down
2 changes: 1 addition & 1 deletion chain/pool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ near-primitives = { path = "../../core/primitives" }
near-chain = { path = "../chain" }

[dev-dependencies]
rand = "0.6"
rand = "0.7"
4 changes: 2 additions & 2 deletions core/crypto/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ edition = "2018"

[dependencies]
sodiumoxide = "0.2.5"
parity-secp256k1 = "0.6.0"
parity-secp256k1 = "0.7.0"

bs58 = "0.2.4"
bs58 = "0.3"
borsh = "0.2.7"
serde = "1.0"
serde_derive = "1.0"
Expand Down
8 changes: 3 additions & 5 deletions core/primitives/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,17 @@ edition = "2018"
[dependencies]
regex = "1"
bincode = { version = "1.0", features = ["i128"] }
bs58 = "0.2.4"
bs58 = "0.3"
base64 = "0.10.1"
byteorder = "1.2"
chrono = { version = "0.4.4", features = ["serde"] }
sodiumoxide = "0.2.5"
lazy_static = "1.4"
serde = "1.0"
serde_derive = "1.0"
sha2 = "0.8.0"
serde_json = "1.0"
rand = "0.6"
rand_xorshift = "0.1"
env_logger = "0.6.0"
rand = "0.7"
env_logger = "0.7"
log = "0.4"
reed-solomon-erasure = "3.1.1"
jemallocator = { version = "0.3.0", optional = true }
Expand Down
4 changes: 2 additions & 2 deletions core/store/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ near-primitives = { path = "../primitives" }

[dev-dependencies]
tempdir = "0.3"
hex-literal = "0.1.1"
hex-literal = "0.2"
bencher = "0.1.5"
rand = "0.6"
rand = "0.7"

[[bench]]
name = "trie_bench"
Expand Down
6 changes: 3 additions & 3 deletions near/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@ byteorder = "1.2"
kvdb = "0.1"
kvdb-memorydb = "0.1"
log = "0.4"
env_logger = "0.6.0"
env_logger = "0.7"
chrono = { version = "0.4.4", features = ["serde"] }
git-version = "0.3.1"
futures = "0.1"
clap = "2.32"
rand = "0.6.5"
rand = "0.7"
serde = "1.0"
serde_derive = "1.0"
serde_json = "1.0"
dirs = "1.0.5"
dirs = "2"
lazy_static = "1.4"

borsh = "0.2.7"
Expand Down
2 changes: 1 addition & 1 deletion runtime/near-vm-logic/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ This crate implements the specification of the interface that Near blockchain ex
"""

[dependencies]
bs58 = "0.2.2"
bs58 = "0.3"
sodiumoxide = { version = "0.2.5", optional = true }
serde = { version = "1.0", features = ["derive"] }
near-runtime-fees = { path = "../near-runtime-fees", version = "0.3.1" }
Expand Down
2 changes: 1 addition & 1 deletion runtime/near-vm-runner/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ parity-wasm = "0.40.1"
[dev-dependencies]
near-vm-logic = { path="../near-vm-logic", features=["mocks"], version = "0.3.0"}
assert_matches = "1.3.0"
wabt = "0.7.4"
wabt = "0.9"
bencher = "0.1.5"

[[bench]]
Expand Down
3 changes: 1 addition & 2 deletions runtime/runtime/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ serde_derive = "1.0"
serde_json = "1.0"
log = "0.4"
kvdb = "0.1"
rand = "0.6"
rand_xorshift = "0.1"
rand = "0.7"
sodiumoxide = "0.2.5"
lazy_static = "1.4"

Expand Down
7 changes: 3 additions & 4 deletions test-utils/loadtester/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ edition = "2018"
[dependencies]
clap = "2.32"
log = "0.4"
env_logger = "0.6.0"
rand = "0.6"
rand_xorshift = "0.1"
hex = "0.3"
env_logger = "0.7"
rand = "0.7"
hex = "0.4"
futures = "0.1.25"
tokio = "0.1"
serde_json = "1.0.0"
Expand Down
2 changes: 1 addition & 1 deletion test-utils/loadtester/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ fn configure_logging(log_level: log::LevelFilter) {
internal_targets.iter().for_each(|internal_targets| {
builder.filter(Some(internal_targets), log_level);
});
builder.default_format_timestamp_nanos(true);
builder.format_timestamp_nanos();
builder.try_init().unwrap();
}

Expand Down
2 changes: 1 addition & 1 deletion test-utils/state-viewer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ edition = "2018"

[dependencies]
clap = "2.32.0"
hex = "0.3"
hex = "0.4"
ansi_term = "0.12.0"
borsh = "0.2.7"

Expand Down
3 changes: 1 addition & 2 deletions test-utils/testlib/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ path = "src/run_nodes.rs"
actix = "0.8.2"
clap = "2.32"
log = "0.4"
rand = "0.6"
rand_xorshift = "0.1"
rand = "0.7"
serde = "1.0"
serde_json = "1.0.0"
tokio = "0.1"
Expand Down