mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 23:51:05 +00:00
Upgrade libp2p to 0.49.0 (#12256)
* cargo upgrade libp2p * Get rid of `NetworkBehaviourEventProcess` in handling of `CustomMessageOutcome` * Get rid of `NetworkBehaviourEventProcess` in handling of `request_responses::Event` * Get rid of `NetworkBehaviourEventProcess` in handling of `peer_info::PeerInfoEvent` * Get rid of `NetworkBehaviourEventProcess` in handling of `DiscoveryOut` * Get rid of `poll()` method in `Bahaviour` * minor: comments * Upgrade libp2p to 0.49.0 (unreleased) * Support multiple Kad protocol names * Make borrow checker happy * minor: wording * Make substrate build with libp2p-0.49.0 * rustfmt * Get rid of MdnsWrapper * Resolve deprecation warnings * Fix documentation * Apply suggestions from code review: fix typos Co-authored-by: Aaro Altonen <48052676+altonen@users.noreply.github.com> * Apply suggestion: simplify kad protocol name matching Co-authored-by: Aaro Altonen <48052676+altonen@users.noreply.github.com>
This commit is contained in:
@@ -21,7 +21,7 @@ codec = { package = "parity-scale-codec", version = "3.0.0", default-features =
|
||||
futures = "0.3.21"
|
||||
futures-timer = "3.0.1"
|
||||
ip_network = "0.4.1"
|
||||
libp2p = { version = "0.46.1", default-features = false, features = ["kad"] }
|
||||
libp2p = { version = "0.49.0", default-features = false, features = ["kad"] }
|
||||
log = "0.4.17"
|
||||
prost = "0.11"
|
||||
rand = "0.7.2"
|
||||
|
||||
@@ -91,10 +91,7 @@ fn cryptos_are_compatible() {
|
||||
let libp2p_public = libp2p_secret.public();
|
||||
|
||||
let sp_core_secret = {
|
||||
let libp2p_ed_secret = match libp2p_secret.clone() {
|
||||
libp2p::identity::Keypair::Ed25519(x) => x,
|
||||
_ => panic!("generate_ed25519 should have generated an Ed25519 key ¯\\_(ツ)_/¯"),
|
||||
};
|
||||
let libp2p::identity::Keypair::Ed25519(libp2p_ed_secret) = libp2p_secret.clone();
|
||||
sp_core::ed25519::Pair::from_seed_slice(&libp2p_ed_secret.secret().as_ref()).unwrap()
|
||||
};
|
||||
let sp_core_public = sp_core_secret.public();
|
||||
|
||||
Reference in New Issue
Block a user