MobilityData / gtfs-realtime-validator

Java-based tool that validates General Transit Feed Specification (GTFS)-realtime feeds
Other
41 stars 10 forks source link

Don't throw W003 for multiple trips in block #68

Open isabelle-dr opened 2 years ago

isabelle-dr commented 2 years ago

Issue by barbeau Jan 07, 2020 Originally opened as https://github.com/CUTR-at-USF/gtfs-realtime-validator/issues/360


Summary:

When a vehicle is serving multiple trips in a block, it is a best practice to include TripUpdates for the current and next trip. However, there will only be a VehiclePosition for the current trip, and as a result a W003 warning is thrown.

We should improve the W003 implementation so it doesn't throw warnings if there is a TripUpdate for the next trip in the block, and a VehiclePosition exists for the TripUpdate for the current trip.

See https://groups.google.com/forum/#!topic/gtfs-realtime/lVPOmi9A5vQ.

The GTFS-rt spec also doesn't currently recommend having TripUpdate for next trip in the block, but it should.

Note that another new rule could potentially throw an error/warning specifically in the case where the feed does NOT provide a prediction for the next trip in the block.

Steps to reproduce:

Run validator on feed with TripUpdates for next trip in block

Expected behavior:

Don't throw W003

Observed behavior:

W003 is thrown

Platform:

N/A

isabelle-dr commented 2 years ago

Comment by barbeau Dec 11, 2021


Recommendations for providing TripUpdates for next trip in block was adopted in PR google/transit#206, so I'm removing the spec clarification label.