Skip to content
Snippets Groups Projects
Commit f103cae7 authored by Jeffrey Wigger's avatar Jeffrey Wigger
Browse files

neighbor fixes 2

parent 39f35073
No related branches found
No related tags found
No related merge requests found
......@@ -44,7 +44,7 @@ procs_per_machine=16
machines=6
global_epochs=160
eval_file=testing.py
log_level=INFO
log_level=DEBUG
ip_machines=$nfs_home/configs/$machine_file # ip_addr_6Machines.json
......
......@@ -413,20 +413,20 @@ class TCPRandomWalkRoutingInternal(TCPRandomWalkBase):
src, data = self.decrypt(sender, recv)
if type(data) == tuple and data[0] == HELLO:
logging.debug("Received {} from {}".format(HELLO, src))
if data[1] == "fw at neighbor": # TODO: this is wrong
# logging.critical(
# "{} wants to connect when already connected!".format(HELLO, src)
# )
# raise RuntimeError(
# "{} wants to connect when already connected!".format(HELLO, src)
# )
# can happen if neighbor is
print("reconnect request from neighbor")
logging.info("reconnect request from neighbor")
return
if src in self.current_neighbors:
if data[1] == "fw at neighbor": # TODO: this is wrong
# logging.critical(
# "{} wants to connect when already connected!".format(HELLO, src)
# )
# raise RuntimeError(
# "{} wants to connect when already connected!".format(HELLO, src)
# )
# can happen if neighbor is
print("reconnect request from neighbor")
logging.info("reconnect request from neighbor")
return
else:
logging.info("fw arrived at a neighbour")
logging.info("fw arrived at a neighbour")
print("fw arrived at a neighbour")
else:
logging.debug("Received {} from {}".format(data, src))
self.add_neighbors(src, data[1])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment