CUTR-at-USF / gtfs-realtime-validator

Java-based tool that validates General Transit Feed Specification (GTFS)-realtime feeds. See https://github.com/MobilityData/gtfs-realtime-validator for the latest!
Other
92 stars 40 forks source link

How should a trip cancellation be represented in a vehicle positions feed? #328

Open barbeau opened 6 years ago

barbeau commented 6 years ago

Summary:

From https://groups.google.com/forum/#!topic/gtfs-realtime/MhXzQyhv9Xs:

In cases where a trip is canceled, the trip_updates feed scheduled_relationship is "CANCELED" for the trip.

In the vehicle_positions feed, is it proper form to 1) remove any records about this trip (as there are no vehicles assigned to this trip) OR 2) is it acceptable to include the trip with schedule_relationship as "CANCELED" and all other information blank in order to provide consistent records?

barbeau commented 6 years ago

This is also related to the broader question of whether vehicle entities should be included in GTFS-rt feeds for non-revenue trips - I posed the question here but we never came to a resolution: https://groups.google.com/forum/#!topic/gtfs-realtime/9ejXOF-5lqU

nselikoff commented 6 years ago

We asked our Google Transit contact whether to include vehicle entities for non-revenue trips and received this response:

"Regarding cases where the vehicle is not assigned a vehicle or route, we usually avoid such data to display on Maps. The realtime transit data is based on the underlying static data and is relying on the route/trip information available there. Therefore, any new data that may be defined in the realtime feed may throw an error/warning."

barbeau commented 6 years ago

@nselikoff Thanks for the info! So is Google implying that they may display non-revenue vehicles on the map if they are in the feed? Or just that these non-revenue vehicles would cause their validator to throw errors if they aren't assigned to trips.

To my knowledge as of today Google doesn't actually show any transit vehicles on a map, so I'm assuming it's the latter.

nselikoff commented 6 years ago

@barbeau pretty sure it's the latter.

However, they're also indicating that they have recently started integrating the vehicle positions feed into Google Maps. I don't have any details beyond that they're working on it + accompanying help center docs.