mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-23 23:04:53 +00:00
Merge stable futures
This commit is contained in:
@@ -9,24 +9,24 @@ edition = "2018"
|
||||
|
||||
[dependencies]
|
||||
clap = "2.33.0"
|
||||
hex = "0.3"
|
||||
hex = "0.4.2"
|
||||
log = "0.4.8"
|
||||
serde = "1.0.102"
|
||||
serde = "1.0.106"
|
||||
serde_yaml = "0.8.11"
|
||||
simple_logger = "1.3.0"
|
||||
simple_logger = "1.6.0"
|
||||
types = { path = "../eth2/types" }
|
||||
state_processing = { path = "../eth2/state_processing" }
|
||||
eth2_ssz = "0.1.2"
|
||||
regex = "1.3.1"
|
||||
regex = "1.3.7"
|
||||
eth1_test_rig = { path = "../tests/eth1_test_rig" }
|
||||
futures = {version = "0.3", features = ["compat"]}
|
||||
futures = { version = "0.3.4", features = ["compat"] }
|
||||
environment = { path = "../lighthouse/environment" }
|
||||
web3 = "0.10.0"
|
||||
eth2_testnet_config = { path = "../eth2/utils/eth2_testnet_config" }
|
||||
dirs = "2.0"
|
||||
dirs = "2.0.2"
|
||||
genesis = { path = "../beacon_node/genesis" }
|
||||
deposit_contract = { path = "../eth2/utils/deposit_contract" }
|
||||
tree_hash = { path = "../eth2/utils/tree_hash" }
|
||||
tokio = { version = "0.2", features = ["full"] }
|
||||
tree_hash = "0.1.0"
|
||||
tokio = { version = "0.2.20", features = ["full"] }
|
||||
clap_utils = { path = "../eth2/utils/clap_utils" }
|
||||
eth2-libp2p = { path = "../beacon_node/eth2-libp2p" }
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
use clap::ArgMatches;
|
||||
use eth2_libp2p::{
|
||||
discovery::{build_enr, CombinedKey, Keypair, ENR_FILENAME},
|
||||
discovery::{build_enr, CombinedKey, CombinedKeyExt, Keypair, ENR_FILENAME},
|
||||
NetworkConfig, NETWORK_KEY_FILENAME,
|
||||
};
|
||||
use std::convert::TryInto;
|
||||
@@ -30,10 +30,7 @@ pub fn run<T: EthSpec>(matches: &ArgMatches) -> Result<(), String> {
|
||||
config.enr_tcp_port = Some(tcp_port);
|
||||
|
||||
let local_keypair = Keypair::generate_secp256k1();
|
||||
let enr_key: CombinedKey = local_keypair
|
||||
.clone()
|
||||
.try_into()
|
||||
.map_err(|e| format!("Unable to convert keypair: {:?}", e))?;
|
||||
let enr_key = CombinedKey::from_libp2p(&local_keypair)?;
|
||||
let enr = build_enr::<T>(&enr_key, &config, EnrForkId::default())
|
||||
.map_err(|e| format!("Unable to create ENR: {:?}", e))?;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user