Closed miklcct closed 3 months ago
Yes, it does. Trains in the DTD system start their day at 4am, which is different to GTFS (and any sane person). I believe that code will look at trains after midnight the previous day and add them in the correct day. I believe they may end up being duplicated at 24:00+ departure trains (e.g. departing 25:30) which is completely valid in GTFS.
It's been many years since I looked at some of this so the details might be off but I believe that's it.
The effect of the code is to add a copy of a train departing Monday 00:30 to depart at Sunday 24:30. I believe it may result in departure boards showing duplicate trains, however I haven't verified it yet in my deployment.
Btw are you the maintainer of gtfs.pro ?
No that's not me. I'm not actually involved with any rail stuff any more. Most of this stuff is just on life support.
It does create duplicated journeys. Note that 00:52 appears twice for the London Overground.
Here is the output of our client now, which is connected to a server with a feed generated by a version without the call removed.
I just re-read the code and it came back to me. Please ignore my first reply.
This was a hack I put in so that when you searched for journeys at the end of the day (e.g. 23:30) it would make connections with services after midnight without having to look for them on the next day.
I suggest we add a flag to disable this behaviour.
After reviewing the GTFS spec, I think I need to restore the use of this function to produce DST-correct feeds.
The reason is because in the GTFS spec, the time of day is defined as starting from noon - 12 hours, which is different from midnight on days with DST changes.
https://github.com/google/transit/pull/15
The correct behaviour is to add a copy of a schedule departing before 02:00 into the previous service day, and remove it from the current service day, such that all services depart between 02:00 and 25:59 (with possible exception of Night Overground services which run on the repeated hour of autumn time change).
I will make a PR soon on this matter as it will affect trip matching when making GTFS-RT feeds.
Upon studying the code,
addLateNightServices
add a copy of the service to the previous day. Won't it produce duplicated service entries?