Skip to content
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

Support for Extended GTFS Route Types #645

Closed
mvanlaar opened this issue Mar 3, 2021 · 5 comments · Fixed by #656
Closed

Support for Extended GTFS Route Types #645

mvanlaar opened this issue Mar 3, 2021 · 5 comments · Fixed by #656
Labels

Comments

@mvanlaar
Copy link
Contributor

mvanlaar commented Mar 3, 2021

NOTE: This issue system is intended for reporting bugs and tracking progress in software development. Although this software is licensed with an open-source license, any issue opened here may not be responded to in a timely manner. Conveyal is unable to provide technical support for custom deployments of this software unless your company has a support contract with us. Please remove this note when creating the issue.

Observed behavior (please include a screenshot if possible)

No support for creating and editing routes with Extended GTFS Route Types

Expected behavior

Support for editing Extended GTFS Route Types

Steps to reproduce the problem

I would like to create 1500 Water Taxi Service and 1000 Water Transport Service route types.

Any special notes on configuration used

none

Version of datatools-ui and datatools-server if applicable (exact commit hash or branch name)

UI Version: | 872d61
Server version: | 11e9a8

Is the support for Extended GTFS Route Types on the roadmap? Or is as simple as editing the .yml config files and creating a pull request for this?

@landonreed
Copy link
Contributor

Hi @mvanlaar, there is support for this in datatools-server:

https://github.com/conveyal/gtfs-lib/blob/048778369dd9d62180fd01cd403b30f9d0ce6966/src/main/java/com/conveyal/gtfs/loader/Table.java#L178-L180

But you're correct in that the UI does not support these values in the Editor. I hesitate to simply update the gtfs.yml file with all of the extended route types (or even just cherry-picking a few), just because they are less commonly used and would complicate that form element for most users. Another approach (though this complicates the implementation) would be to show the primary options and allow custom input for values between, say, 13 and 1800. This issue also highlights that the routes#route_typefield in gtfs.yml is missing values 8 through 12, which have already been incorporated into the GTFS spec.

I'll take a look at the code and will update this ticket with more info.

@landonreed landonreed added the bug label Mar 5, 2021
@mvanlaar
Copy link
Contributor Author

mvanlaar commented Mar 5, 2021

I've added in my local copy the google supported values. Thats working.

@mvanlaar
Copy link
Contributor Author

mvanlaar commented Mar 8, 2021

We could try to make it a optgroup for the primary values and a optgroup for the secondary options.

@landonreed
Copy link
Contributor

Yes, that might be a nice solution. Another solution I was considering was using React Select with creatable options: https://react-select.com/creatable

@mvanlaar
Copy link
Contributor Author

mvanlaar commented Mar 9, 2021

Is this something that we can use also for the fares? #551 #566 ? Because this more of the same, larger list that are supported but you want sometimes to show only a portion.

robertgregg3 pushed a commit that referenced this issue Apr 8, 2021
Added the route types to the GTFS.yml file and then added logic to display the route_type field in
an optgroup

#645
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants