diff --git a/src/runtime2/component/consensus.rs b/src/runtime2/component/consensus.rs index b2bdfc0e49dedcc60515ed2e41aa32c3c5f874cb..666ecf3c637103d1c7646b01252373c244637536 100644 --- a/src/runtime2/component/consensus.rs +++ b/src/runtime2/component/consensus.rs @@ -424,6 +424,19 @@ impl Consensus { self.highest_id = header.highest_id; for peer in comp_ctx.iter_peers() { if peer.id == header.sending_id { + continue; // do not send to sender: it has the higher ID + } + + // also: only send if we received a message in this round + let mut performed_communication = false; // TODO: Revise, temporary fix + for port in self.ports.iter() { + if port.peer_comp_id == peer.id && port.mapping.is_some() { + performed_communication = true; + break; + } + } + + if !performed_communication { continue; }