def get_discovery_protocol(seed=b"seed"): privkey = keys.PrivateKey(keccak(seed)) return discovery.DiscoveryProtocol(privkey, random_address(), bootstrap_nodes=[])
def get_discovery_protocol(seed=b"seed", address=None): privkey = keys.PrivateKey(keccak(seed)) if address is None: address = random_address() return discovery.DiscoveryProtocol(privkey, address, [], CancelToken("discovery-test"))
def get_discovery_protocol(seed=b"seed"): privkey = keys.PrivateKey(keccak(seed)) return discovery.DiscoveryProtocol(privkey, random_address(), [], CancelToken("discovery-test"))