forked from LBRYCommunity/lbry-sdk
logging and docstring
This commit is contained in:
parent
cb09be5336
commit
5013426e02
2 changed files with 6 additions and 1 deletions
|
@ -176,6 +176,11 @@ class Node(object):
|
|||
raise ValueError("%s lbrynet may already be running." % str(e))
|
||||
|
||||
def bootstrap_join(self, known_node_addresses, finished_d):
|
||||
"""
|
||||
Attempt to join the dht, retry every 30 seconds if unsuccessful
|
||||
:param known_node_addresses: [(str, int)] list of hostnames and ports for known dht seed nodes
|
||||
:param finished_d: (defer.Deferred) called when join succeeds
|
||||
"""
|
||||
@defer.inlineCallbacks
|
||||
def _resolve_seeds():
|
||||
bootstrap_contacts = []
|
||||
|
|
|
@ -211,7 +211,7 @@ class KademliaProtocol(protocol.DatagramProtocol):
|
|||
message = self._translator.fromPrimitive(msgPrimitive)
|
||||
except (encoding.DecodeError, ValueError) as err:
|
||||
# We received some rubbish here
|
||||
log.exception("Decode error: %s", err)
|
||||
log.exception("Error decoding datagram from %s:%i - %s", address[0], address[1], err)
|
||||
return
|
||||
except (IndexError, KeyError):
|
||||
log.warning("Couldn't decode dht datagram from %s", address)
|
||||
|
|
Loading…
Reference in a new issue