-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exception based scheduling #385
Conversation
… calednar dates to define trip
…t are not related to calendars
…iling unit tests):
…ordering can be used in MergeLi
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to play with this code more, but see my comments so far.
src/main/java/com/conveyal/gtfs/loader/JdbcGtfsSnapshotter.java
Outdated
Show resolved
Hide resolved
src/main/java/com/conveyal/gtfs/loader/JdbcGtfsSnapshotter.java
Outdated
Show resolved
Hide resolved
src/main/java/com/conveyal/gtfs/loader/JdbcGtfsSnapshotter.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm able to replicate a correct export of a schedule exception not linked to a calendar (with some cheating), so I will go ahead and approve subject to the refactorings I mentioned in my previous comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good, but right now I'm a bit confused about the use of the ScheduleException
name as the service_id for a calendar_date based service. For example, calendar_dates may be used to add service on 2023-05-29 and 2023-07-04 for a service ID "4" which does not exist in calendar.txt. These would be represented as two separate calendar_dates but right now result in two separate ScheduleExceptions but with the same name
. How should this use case be handled if we requiring name to be unique?
Co-authored-by: Philip Cline <[email protected]>
@philip-cline How does this look? If the calendar date is not assoicated with a calendar the name is made up of service id and the first date. For |
…ule exceptions for a single ser
Thanks yeah this is looking good. I'll start on a front end PR for this. |
…ption based service
…re/DT-183-Exception-based-scheduling
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM to me now
Checklist
dev
before they can be merged tomaster
)Description
The crux of this feature is to allow calendar dates (which are not associated to a calendar, as this is already imlemented) to be loaded, snapshotted and exported without the need to be joined to a calendar. This then allows calendar date services to be defined in their own right and not tied to a calendar.
From the spec (https://developers.google.com/transit/gtfs/reference#calendar_datestxt) this will allow the alternative approach to using calendar dates.
It should be possible under the UI to define a calendar date service by providing the following:
It is assumed that: