Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
chore: update some deps to prune duplicated deps (#14515)
Browse files Browse the repository at this point in the history
* chore: update some deps to prune duplicated deps

- array-bytes: 4.1.0 => 6.1.0
- cid: 0.8.6 => 0.9.0

* fix
  • Loading branch information
koushiro authored Jul 6, 2023
1 parent c32f5ed commit 69b6549
Show file tree
Hide file tree
Showing 47 changed files with 126 additions and 163 deletions.
135 changes: 51 additions & 84 deletions Cargo.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion bin/node/bench/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ publish = false
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
clap = { version = "4.2.5", features = ["derive"] }
log = "0.4.17"
node-primitives = { version = "2.0.0", path = "../primitives" }
Expand Down
2 changes: 1 addition & 1 deletion bin/node/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ crate-type = ["cdylib", "rlib"]

[dependencies]
# third-party dependencies
array-bytes = "4.1"
array-bytes = "6.1"
clap = { version = "4.2.5", features = ["derive"], optional = true }
codec = { package = "parity-scale-codec", version = "3.6.1" }
serde = { version = "1.0.163", features = ["derive"] }
Expand Down
2 changes: 1 addition & 1 deletion client/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ readme = "README.md"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
chrono = "0.4.10"
clap = { version = "4.2.5", features = ["derive", "string"] }
fdlimit = "0.2.1"
Expand Down
2 changes: 1 addition & 1 deletion client/cli/src/commands/generate_node_key.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ impl GenerateNodeKeyCmd {
let file_data = if self.bin {
secret.as_ref().to_owned()
} else {
array_bytes::bytes2hex("", secret.as_ref()).into_bytes()
array_bytes::bytes2hex("", secret).into_bytes()
};

match &self.file {
Expand Down
2 changes: 1 addition & 1 deletion client/consensus/beefy/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ description = "BEEFY Client gadget for substrate"
homepage = "https://substrate.io"

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
async-channel = "1.8.0"
async-trait = "0.1.57"
codec = { package = "parity-scale-codec", version = "3.6.1", features = ["derive"] }
Expand Down
2 changes: 1 addition & 1 deletion client/consensus/beefy/src/communication/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ mod tests {
use beefy_protocol_name::{gossip_protocol_name, justifications_protocol_name};
// Create protocol name using random genesis hash.
let genesis_hash = H256::random();
let genesis_hex = array_bytes::bytes2hex("", genesis_hash.as_ref());
let genesis_hex = array_bytes::bytes2hex("", genesis_hash);

let expected_gossip_name = format!("/{}/beefy/2", genesis_hex);
let gossip_proto_name = gossip_protocol_name(&genesis_hash, None);
Expand Down
2 changes: 1 addition & 1 deletion client/consensus/grandpa/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
ahash = "0.8.2"
array-bytes = "4.1"
array-bytes = "6.1"
async-trait = "0.1.57"
dyn-clone = "1.0"
finality-grandpa = { version = "0.16.2", features = ["derive-codec"] }
Expand Down
2 changes: 1 addition & 1 deletion client/consensus/grandpa/src/communication/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -669,7 +669,7 @@ fn grandpa_protocol_name() {

// Create protocol name using random genesis hash.
let genesis_hash = sp_core::H256::random();
let expected = format!("/{}/grandpa/1", array_bytes::bytes2hex("", genesis_hash.as_ref()));
let expected = format!("/{}/grandpa/1", array_bytes::bytes2hex("", genesis_hash));
let proto_name = grandpa_protocol_name::standard_name(&genesis_hash, &chain_spec);
assert_eq!(proto_name.to_string(), expected);

Expand Down
2 changes: 1 addition & 1 deletion client/db/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ quickcheck = { version = "1.0.3", default-features = false }
kitchensink-runtime = { path = "../../bin/node/runtime" }
sp-tracing = { version = "10.0.0", path = "../../primitives/tracing" }
substrate-test-runtime-client = { version = "2.0.0", path = "../../test-utils/runtime/client" }
array-bytes = "4.1"
array-bytes = "6.1"

[features]
default = []
Expand Down
2 changes: 1 addition & 1 deletion client/executor/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ sp-version = { version = "22.0.0", path = "../../primitives/version" }
sp-wasm-interface = { version = "14.0.0", path = "../../primitives/wasm-interface" }

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
assert_matches = "1.3.0"
wat = "1.0"
sc-runtime-test = { version = "2.0.0", path = "runtime-test" }
Expand Down
2 changes: 1 addition & 1 deletion client/keystore/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ readme = "README.md"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
parking_lot = "0.12.1"
serde_json = "1.0.85"
thiserror = "1.0"
Expand Down
2 changes: 1 addition & 1 deletion client/network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ readme = "README.md"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
async-channel = "1.8.0"
async-trait = "0.1"
asynchronous-codec = "0.6"
Expand Down
2 changes: 1 addition & 1 deletion client/network/bitswap/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ prost-build = "0.11"

[dependencies]
async-channel = "1.8.0"
cid = "0.8.6"
cid = "0.9.0"
futures = "0.3.21"
libp2p-identity = { version = "0.1.2", features = ["peerid"] }
log = "0.4.17"
Expand Down
2 changes: 1 addition & 1 deletion client/network/light/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ prost-build = "0.11"

[dependencies]
async-channel = "1.8.0"
array-bytes = "4.1"
array-bytes = "6.1"
codec = { package = "parity-scale-codec", version = "3.6.1", features = [
"derive",
] }
Expand Down
2 changes: 1 addition & 1 deletion client/network/statement/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ documentation = "https://docs.rs/sc-network-statement"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
async-channel = "1.8.0"
codec = { package = "parity-scale-codec", version = "3.6.1", features = ["derive"] }
futures = "0.3.21"
Expand Down
2 changes: 1 addition & 1 deletion client/network/sync/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ targets = ["x86_64-unknown-linux-gnu"]
prost-build = "0.11"

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
async-channel = "1.8.0"
async-trait = "0.1.58"
codec = { package = "parity-scale-codec", version = "3.6.1", features = ["derive"] }
Expand Down
2 changes: 1 addition & 1 deletion client/network/transactions/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ documentation = "https://docs.rs/sc-network-transactions"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
codec = { package = "parity-scale-codec", version = "3.6.1", features = ["derive"] }
futures = "0.3.21"
libp2p = "0.51.3"
Expand Down
2 changes: 1 addition & 1 deletion client/offchain/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ readme = "README.md"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
bytes = "1.1"
codec = { package = "parity-scale-codec", version = "3.6.1", features = ["derive"] }
fnv = "1.0.6"
Expand Down
2 changes: 1 addition & 1 deletion client/rpc-spec-v2/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ hex = "0.4"
futures = "0.3.21"
parking_lot = "0.12.1"
tokio-stream = { version = "0.1", features = ["sync"] }
array-bytes = "4.1"
array-bytes = "6.1"
log = "0.4.17"
futures-util = { version = "0.3.19", default-features = false }

Expand Down
2 changes: 1 addition & 1 deletion client/service/test/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
async-channel = "1.8.0"
array-bytes = "4.1"
array-bytes = "6.1"
fdlimit = "0.2.1"
futures = "0.3.21"
log = "0.4.17"
Expand Down
2 changes: 1 addition & 1 deletion client/transaction-pool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ sp-tracing = { version = "10.0.0", path = "../../primitives/tracing" }
sp-transaction-pool = { version = "4.0.0-dev", path = "../../primitives/transaction-pool" }

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
assert_matches = "1.3.0"
criterion = "0.4.0"
sc-block-builder = { version = "0.10.0-dev", path = "../block-builder" }
Expand Down
4 changes: 2 additions & 2 deletions frame/alliance/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ readme = "README.md"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = { version = "4.1", optional = true }
array-bytes = { version = "6.1", optional = true }
log = { version = "0.4.14", default-features = false }

codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false, features = ["derive"] }
Expand All @@ -33,7 +33,7 @@ pallet-identity = { version = "4.0.0-dev", path = "../identity", default-feature
pallet-collective = { version = "4.0.0-dev", path = "../collective", default-features = false, optional = true }

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
sp-core-hashing = { version = "9.0.0", default-features = false, path = "../../primitives/core/hashing" }
pallet-balances = { version = "4.0.0-dev", path = "../balances" }
pallet-collective = { version = "4.0.0-dev", path = "../collective" }
Expand Down
4 changes: 2 additions & 2 deletions frame/beefy-mmr/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ repository = "https://github.com/paritytech/substrate"
homepage = "https://substrate.io"

[dependencies]
array-bytes = { version = "4.1", optional = true }
array-bytes = { version = "6.1", optional = true }
codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false, features = ["derive"] }
log = { version = "0.4.17", default-features = false }
scale-info = { version = "2.5.0", default-features = false, features = ["derive"] }
Expand All @@ -28,7 +28,7 @@ sp-std = { version = "8.0.0", default-features = false, path = "../../primitives
sp-api = { version = "4.0.0-dev", default-features = false, path = "../../primitives/api" }

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
sp-staking = { version = "4.0.0-dev", path = "../../primitives/staking" }

[features]
Expand Down
6 changes: 3 additions & 3 deletions frame/beefy-mmr/src/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ fn should_update_authorities() {
// check current authority set
assert_eq!(0, auth_set.id);
assert_eq!(2, auth_set.len);
let want = array_bytes::hex_n_into_unchecked::<H256, 32>(
let want = array_bytes::hex_n_into_unchecked::<_, H256, 32>(
"176e73f1bf656478b728e28dd1a7733c98621b8acf830bff585949763dca7a96",
);
assert_eq!(want, auth_set.root);
Expand All @@ -184,7 +184,7 @@ fn should_update_authorities() {
assert_eq!(1, auth_set.id);
// check next auth set
assert_eq!(2, next_auth_set.id);
let want = array_bytes::hex_n_into_unchecked::<H256, 32>(
let want = array_bytes::hex_n_into_unchecked::<_, H256, 32>(
"9c6b2c1b0d0b25a008e6c882cc7b415f309965c72ad2b944ac0931048ca31cd5",
);
assert_eq!(2, next_auth_set.len);
Expand All @@ -200,7 +200,7 @@ fn should_update_authorities() {
assert_eq!(2, auth_set.id);
// check next auth set
assert_eq!(3, next_auth_set.id);
let want = array_bytes::hex_n_into_unchecked::<H256, 32>(
let want = array_bytes::hex_n_into_unchecked::<_, H256, 32>(
"9c6b2c1b0d0b25a008e6c882cc7b415f309965c72ad2b944ac0931048ca31cd5",
);
assert_eq!(2, next_auth_set.len);
Expand Down
2 changes: 1 addition & 1 deletion frame/benchmarking/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ sp-storage = { version = "13.0.0", default-features = false, path = "../../primi
static_assertions = "1.1.0"

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
rusty-fork = { version = "0.3.0", default-features = false }
sp-keystore = { version = "0.27.0", path = "../../primitives/keystore" }

Expand Down
2 changes: 1 addition & 1 deletion frame/contracts/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ sp-runtime = { version = "24.0.0", default-features = false, path = "../../primi
sp-std = { version = "8.0.0", default-features = false, path = "../../primitives/std" }

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
assert_matches = "1"
env_logger = "0.9"
pretty_assertions = "1"
Expand Down
4 changes: 3 additions & 1 deletion frame/contracts/src/exec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3608,7 +3608,9 @@ mod tests {
);
assert_eq!(
ctx.ext.ecdsa_to_eth_address(&pubkey_compressed).unwrap(),
array_bytes::hex2array_unchecked::<20>("09231da7b19A016f9e576d23B16277062F4d46A8")
array_bytes::hex2array_unchecked::<_, 20>(
"09231da7b19A016f9e576d23B16277062F4d46A8"
)
);
exec_success()
});
Expand Down
2 changes: 1 addition & 1 deletion frame/contracts/src/wasm/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2180,7 +2180,7 @@ mod tests {
ExecReturnValue {
flags: ReturnFlags::empty(),
data: (
array_bytes::hex2array_unchecked::<32>(
array_bytes::hex2array_unchecked::<_, 32>(
"000102030405060708090A0B0C0D0E0F000102030405060708090A0B0C0D0E0F"
),
42u64,
Expand Down
2 changes: 1 addition & 1 deletion frame/executive/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ sp-std = { version = "8.0.0", default-features = false, path = "../../primitives
sp-tracing = { version = "10.0.0", default-features = false, path = "../../primitives/tracing" }

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
pallet-balances = { version = "4.0.0-dev", path = "../balances" }
pallet-transaction-payment = { version = "4.0.0-dev", path = "../transaction-payment" }
sp-core = { version = "21.0.0", path = "../../primitives/core" }
Expand Down
2 changes: 1 addition & 1 deletion frame/merkle-mountain-range/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ sp-runtime = { version = "24.0.0", default-features = false, path = "../../primi
sp-std = { version = "8.0.0", default-features = false, path = "../../primitives/std" }

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
env_logger = "0.9"
itertools = "0.10.3"

Expand Down
2 changes: 1 addition & 1 deletion frame/support/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ serde_json = "1.0.85"
assert_matches = "1.3.0"
pretty_assertions = "1.2.1"
frame-system = { version = "4.0.0-dev", path = "../system" }
array-bytes = "4.1"
array-bytes = "6.1"

[features]
default = ["std"]
Expand Down
2 changes: 1 addition & 1 deletion frame/transaction-storage/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ readme = "README.md"
targets = ["x86_64-unknown-linux-gnu"]

[dependencies]
array-bytes = { version = "4.1", optional = true }
array-bytes = { version = "6.1", optional = true }
codec = { package = "parity-scale-codec", version = "3.6.1", default-features = false }
scale-info = { version = "2.5.0", default-features = false, features = ["derive"] }
serde = { version = "1.0.163", optional = true }
Expand Down
2 changes: 1 addition & 1 deletion primitives/consensus/beefy/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ strum = { version = "0.24.1", features = ["derive"], default-features = false }
lazy_static = "1.4.0"

[dev-dependencies]
array-bytes = "4.1"
array-bytes = "6.1"
sp-keystore = { version = "0.27.0", path = "../../keystore" }

[features]
Expand Down
2 changes: 1 addition & 1 deletion primitives/core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ bitflags = "1.3"
paste = "1.0.7"

# full crypto
array-bytes = { version = "4.1", optional = true }
array-bytes = { version = "6.1", optional = true }
ed25519-zebra = { version = "3.1.0", default-features = false, optional = true }
blake2 = { version = "0.10.4", default-features = false, optional = true }
libsecp256k1 = { version = "0.7", default-features = false, features = ["static-context"], optional = true }
Expand Down
2 changes: 1 addition & 1 deletion primitives/core/src/bls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,7 @@ impl<T> Serialize for Signature<T> {
where
S: Serializer,
{
serializer.serialize_str(&array_bytes::bytes2hex("", self.as_ref()))
serializer.serialize_str(&array_bytes::bytes2hex("", self))
}
}

Expand Down
4 changes: 2 additions & 2 deletions primitives/core/src/ecdsa.rs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ impl Serialize for Signature {
where
S: Serializer,
{
serializer.serialize_str(&array_bytes::bytes2hex("", self.as_ref()))
serializer.serialize_str(&array_bytes::bytes2hex("", self))
}
}

Expand Down Expand Up @@ -552,7 +552,7 @@ mod test {
let derived = pair.derive(path.into_iter(), None).ok().unwrap();
assert_eq!(
derived.0.seed(),
array_bytes::hex2array_unchecked::<32>(
array_bytes::hex2array_unchecked::<_, 32>(
"b8eefc4937200a8382d00050e050ced2d4ab72cc2ef1b061477afb51564fdd61"
)
);
Expand Down
4 changes: 2 additions & 2 deletions primitives/core/src/ed25519.rs
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ impl Serialize for Signature {
where
S: Serializer,
{
serializer.serialize_str(&array_bytes::bytes2hex("", self.as_ref()))
serializer.serialize_str(&array_bytes::bytes2hex("", self))
}
}

Expand Down Expand Up @@ -499,7 +499,7 @@ mod test {
let derived = pair.derive(path.into_iter(), None).ok().unwrap().0;
assert_eq!(
derived.seed(),
array_bytes::hex2array_unchecked::<32>(
array_bytes::hex2array_unchecked::<_, 32>(
"ede3354e133f9c8e337ddd6ee5415ed4b4ffe5fc7d21e933f4930a3730e5b21c"
)
);
Expand Down
2 changes: 1 addition & 1 deletion primitives/core/src/sr25519.rs
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ impl Serialize for Signature {
where
S: Serializer,
{
serializer.serialize_str(&array_bytes::bytes2hex("", self.as_ref()))
serializer.serialize_str(&array_bytes::bytes2hex("", self))
}
}

Expand Down
Loading

0 comments on commit 69b6549

Please sign in to comment.