Commit c1c384a3 authored by Georgios Dagkakis's avatar Georgios Dagkakis

ScheduledBreak: synchronisation check

parent ab292aef
...@@ -95,9 +95,10 @@ class ScheduledBreak(ObjectInterruption): ...@@ -95,9 +95,10 @@ class ScheduledBreak(ObjectInterruption):
# if SkilledRouter waits for the station to finish, send this signal to this router # if SkilledRouter waits for the station to finish, send this signal to this router
from Globals import G from Globals import G
from dream.simulation.SkilledOperatorRouter import SkilledRouter from dream.simulation.SkilledOperatorRouter import SkilledRouter
if G.RouterList[0].__class__ is SkilledRouter: if G.RouterList[0].__class__ is SkilledRouter and \
if station.id in G.RouterList[0].expectedFinishSignalsDict.keys(): station.id in G.RouterList[0].expectedFinishSignalsDict.keys() and \
self.sendSignal(receiver=G.RouterList[0], signal=G.RouterList[0].expectedFinishSignalsDict[station.id], not G.RouterList[0].expectedFinishSignalsDict[station.id].triggered:
self.sendSignal(receiver=G.RouterList[0], signal=G.RouterList[0].expectedFinishSignalsDict[station.id],
sender=station) sender=station)
if self.victim.schedule: if self.victim.schedule:
if not self.victim.schedule[-1].get("exitTime", None): if not self.victim.schedule[-1].get("exitTime", None):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment