-
Notifications
You must be signed in to change notification settings - Fork 45
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
In Routes.txt the route_desc should be optional but it appears manditory. #24
Comments
I have a related scenario where I have line like thus: Where you can see the data array has 7 elements. The header however has 8 elements as it includes route_desc which causes issues (only for the one row with double quotes around the first cell. Most of my rows work fine interestingly appart from row 236 which only seems odd as it has quotes in the first field as thus (it has quotes because it has a comma in the name which is what is causing issues I think): "HC Station to Orewa, via Silverdale and Red Beach Rd" ,3 , ,NZBNS ,98402-20151209115617_v35.34 , ,984 All other rows are more like: Carmel College And Westlake Girls To Glenfield ,3 , ,NZBNS ,04652-20151126154057_v35.16 , ,046 The headers in the file are: route_long_name ,route_type,route_text_color,agency_id ,route_id,route_color,route_short_name I think the issues are:
|
Can you create a unittest that reproduces these issues? It's difficult to follow without access to the data you're using. |
Firstly issue number 1, If you change your routes.txt in the unit test project to be (ie remove the route_desc column): route_id,agency_id,route_short_name,route_long_name,route_type,route_url,route_color,route_text_color Then it will give the following error: GTFS.Exceptions.GTFSRequiredFieldMissingException : Required field route_desc not found in routes. at GTFS.GTFSReader That field should be optional according to the GTFS spec. |
For issue number 2 I can no longer reproduce this. The quotations do correctly tokenize the comma within (at least when trying through unit testing). I will keep an eye out for the issue and how to repro if I can. For now issue number 2 mentioned above can be ignored. Thanks. |
I have fixed the first issue, see issue #30. |
See here: https://developers.google.com/transit/gtfs/reference?hl=en#routes_fields
The text was updated successfully, but these errors were encountered: