The arrival and departure times of each trip are read in order of
stop_sequence, ignoring blank times. A time more than 12 hours earlier
than the previous time of its trip is taken as a time after midnight, so
it and the later times of the trip are moved one day later (e.g.
"00:10:00" becomes "24:10:00"). Trips that run past a second midnight
are moved two days, and so on. A time more than 12 hours later than the
previous time of its trip undoes one of these days, so feeds that mix both
forms are also fixed (e.g. "24:30:00", "00:40:00", "24:50:00"
becomes "24:30:00", "24:40:00", "24:50:00"), and trips whose times
already follow the specification are left unchanged. Blank times are kept
blank. Only stop_times and frequencies are modified; their existing
_secs columns are updated to match.
Times earlier than the previous time of their trip by 12 hours or less are
left unchanged, with a warning. Times are never moved earlier, so trips
with known times more than 12 hours apart that follow the specification
(e.g. "06:00:00", "19:30:00") are left unchanged. Rows with a missing
trip_id or stop_sequence are left unchanged, and stops with duplicated
stop_sequences are read in the order of their rows (see
remove_duplicates()).
Trips whose times are all written after midnight as early morning times
(e.g. a trip of the previous service day departing at "00:30:00") can't
be told apart from trips of the service day and are left unchanged.
In frequencies, an end_time earlier than the start_time of its row
is moved by whole days to the first time later than the start_time
(e.g. "23:00:00"-"01:00:00" becomes "23:00:00"-"25:00:00"). A
start_time written as an early morning time is left unchanged. The
template times of trips listed in frequencies are fixed as any other
times, which doesn't change their departures, since only the differences
between them are used.
An error is raised if a fixed time would be later than "9999:59:59".