Change argument name of Network.listen and blakc format

This commit is contained in:
NIC619
2019-08-01 13:25:20 +08:00
parent cd684aad9e
commit 924e965537
7 changed files with 23 additions and 35 deletions

View File

@ -212,10 +212,10 @@ class KademliaServer:
"""
log.info("Saving state to %s", fname)
data = {
'ksize': self.ksize,
'alpha': self.alpha,
'id': self.node.peer_id_bytes,
'neighbors': self.bootstrappable_neighbors()
"ksize": self.ksize,
"alpha": self.alpha,
"id": self.node.peer_id_bytes,
"neighbors": self.bootstrappable_neighbors(),
}
if not data["neighbors"]:
log.warning("No known neighbors, so not writing to cache.")