Delay is not updated in is_timewindow_violated_dueto_insertion()
matdahl opened this issue · 1 comments
matdahl commented
Shouldn't this update the delay/delta_cpat
variable defined in
so that the new delay is used when checking the next stop?
Currently, the value computed in this line is lost after leaving the else
block.
PS: to check whether the delay totally vanished, it's more save to check new_departure == old_departure
or even better stop->time_window_min >= stop->estimated_arrival_time + delta_cpat
to avoid rounding errors that might prevent breaking the loop here.