MobilityData / gtfs-validator

Canonical GTFS Validator project for schedule (static) files.
https://gtfs-validator.mobilitydata.org/
Apache License 2.0
275 stars 100 forks source link

Implement stops and stations too close validation (GTFS Rule) #154

Open maximearmstrong opened 4 years ago

maximearmstrong commented 4 years ago

Is your feature request related to a problem? Please describe. Two stations should not be too close or too far from each other. This is a GTFS rule implemented in Google Python validator and featured in Google Type Error as TYPE_STATIONS_TOO_CLOSE, TYPE_STOPS_TOO_CLOSE, TYPE_STOP_TOO_CLOSE_TO_STATION and TYPE_STOP_TOO_FAR_FROM_PARENT_STATION.

Describe the solution you'd like Actual Google GTFS validator behaviour : verifies if two stops are closer than 2 meters, and if stations are too close (considering the stops). Verifies if two stops are closer than 1000 meters apart, if not they are too far from each other.

Describe alternatives you've considered

Additional context Line 91, 105, 106 and 116 in Error support priorities https://docs.google.com/spreadsheets/d/1vqe6wq7ctqk1EhYkgtZ0_TbcQ91vccfs2daSjn20BLE/edit#gid=0

barbeau commented 4 years ago

cc @timMillet

Same here, these thresholds aren't in the spec or best practices:

isabelle-dr commented 1 year ago

There is no mention of this check in the spec or best practices. That being said, we have heard from users that looking for duplicated stops in a dataset is one of their use cases for using a GTFS validator. They still need to use Google's python validator until this validator provides this type of check.

Adding a "Needs discussion" label to see if we could make an exception for this one is similar to the rules we have for fast travel (fast_travel_between_consecutive_stops and fast_travel_between_far_stops). They aren't based on the spec, but are seen as valuable checks from the community so they got added to this project.

isabelle-dr commented 1 year ago

@bdferris-v2 we could potentially have this as INFO until we reach a consensus on https://github.com/MobilityData/GTFS_Schedule_Best-Practices/pull/50. This particular check has been brought up a few times by users. Some of them even have a workflow where they only check for potential duplicate stops in a GTFS dataset.