Skip to content

Commit

Permalink
Debug
Browse files Browse the repository at this point in the history
  • Loading branch information
grimadas committed Sep 19, 2023
1 parent ce2fe8d commit d176882
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/bami/broadcast/community.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,14 +56,14 @@ def __init__(self, *args, **kwargs) -> None:
self.add_message_handler(TransactionPayload, self.received_transaction)

def ez_send(self, peer: Peer, *payloads: AnyPayload, **kwargs) -> None:
if self.latency_sim:
latency = self.sim_net.get_link_latency(self.my_peer_id, peer.public_key.key_to_bin())
self.register_anonymous_task("send",
super().ez_send,
peer, *payloads, **kwargs,
delay=latency)
else:
super().ez_send(peer, *payloads, **kwargs)
super().ez_send(peer, *payloads, **kwargs)
# if self.latency_sim:
# latency = self.sim_net.get_link_latency(self.my_peer_id, peer.public_key.key_to_bin())
# self.register_anonymous_task("send",
# super().ez_send,
# peer, payloads
# delay=latency)


def create_introduction_request(self, socket_address, extra_bytes=b'', new_style=False, prefix=None):
extra_bytes = self.is_transaction_creator.to_bytes(1, 'big')
Expand Down

0 comments on commit d176882

Please sign in to comment.