mecatran/gtfsvtor

Add better support for extended route_types

Closed this issue · 1 comments

Currently, Google's extended route_types, e.g. in TooFastTravelVallidator are supported via custom configuration.

I suggest to at least provide a sample config for a feed with these extended route types with their backward compatible maxspeeds.

As some other checks (e.g. for stops served by multiple route_types #17) will require some logic to map extended route_types to a standard route_type, an additional generalization functionallity like OTP's TraverseMode would make sense as well.

Good suggestion. Indeed right now Gtfsvtor allow extended route types during loading, but the speed validator do not use proper default values (In the code the default speed value for an extended type is 50 km/h, the lowest one). I guess we could add an helper method that return the "basic" type from the extended type in the GtfsRouteType method.

For speed configuration we would use the following mechanism: In the case a route has an extended type, if the configuration is present for this ext type we should use it; if not we should fallback on configured value for the basic equivalent type.