-
Notifications
You must be signed in to change notification settings - Fork 114
Description
What problem in GTFS datasets does this new rule address? Please describe.
In some feeds, I have seen records in the shapes.txt file where two rows of data have the exact same GPS coordinate and exact shape_dist_traveled value. The current behavior of the validator treats this as a severe error. Although it is a somewhat duplicative record, I wouldn't think that it would qualify as a severe error and probably has no noticeable effect to an end user when shown a shape in a trip planner UI.
Describe the new validation rule
The code as follows should have more nuance:
Line 52 in cbc9513
| && prev.shapeDistTraveled() >= curr.shapeDistTraveled()) { |
The code should also look to see if the GPS coordinates in the previous record were the same GPS coordinates in the current record and as long as the shape_dist_traveled value is also equal, a notice should be generated, but the severity of that notice should be only a warning.
Error vs warning
There should still be an error if the shape_dist_traveled is equal but the GPS coordinates change. But if the coordinates are the same and the shape_dist_traveled is the same, only a warning should be generated.