diff --git a/src/runtime2/component/component_pdl.rs b/src/runtime2/component/component_pdl.rs index f42259ea5a5a711d30d44cd09e1f4ab459aba2c8..fb391058dfb1bdfad2b058ca73c5eaec63cfe33e 100644 --- a/src/runtime2/component/component_pdl.rs +++ b/src/runtime2/component/component_pdl.rs @@ -312,8 +312,7 @@ impl CompPDL { /// the internal `Mode`, such that the next call to `run` can take the /// appropriate next steps. fn handle_sync_decision(&mut self, sched_ctx: &SchedulerCtx, comp_ctx: &mut CompCtx, decision: SyncRoundDecision) { - debug_assert_eq!(self.mode, Mode::SyncEnd); - sched_ctx.log(&format!("Handling sync decision: {:?}", decision)); + sched_ctx.log(&format!("Handling sync decision: {:?} (in mode {:?})", decision, self.mode)); let is_success = match decision { SyncRoundDecision::None => { // No decision yet @@ -324,6 +323,7 @@ impl CompPDL { }; // If here then we've reached a decision + debug_assert_eq!(self.mode, Mode::SyncEnd); if is_success { self.mode = Mode::NonSync; self.consensus.notify_sync_decision(decision); @@ -531,7 +531,6 @@ impl CompPDL { fn handle_incoming_sync_message(&mut self, sched_ctx: &SchedulerCtx, comp_ctx: &mut CompCtx, message: SyncMessage) { let decision = self.consensus.receive_sync_message(sched_ctx, comp_ctx, message); - debug_assert!(self.mode == Mode::Sync || self.mode == Mode::SyncEnd); self.handle_sync_decision(sched_ctx, comp_ctx, decision); }