Règles de validation
Le catalogue ci-dessous liste chaque règle compilée dans gapline. Filtrez par sévérité, par stage, ou cherchez un ID. Utilisez le rule_id matché comme argument de --disable-rule pour faire taire une règle sur un run.
Certaines règles émettent plusieurs codes d’anomalie (par exemple speed_validation émet zero_speed et unrealistic_speed). Chaque code est listé avec sa règle parente : désactivez le code pour ne faire taire que lui, ou la règle parente pour tous ses codes.
| Rule ID | Severity | Stage |
|---|---|---|
alert_target_not_in_schedule | Warning | Realtime |
alert_without_target | Warning | Realtime |
block_id_trip_overlap | Error | Semantic |
calendar_dates_coherence | Warning | Semantic |
calendar_dates_service_not_in_calendar | Warning | Semantic |
calendar_ranges | Error | Semantic |
case_sensitive_name | Error | Structural |
consecutive_same_stop_id | Error | Realtime |
control_character | Error | Structural |
conveyal_trip_without_shape | Warning | Semantic |
coordinate_out_of_range | Error | Semantic |
coordinates_near_origin | Warning | Semantic |
coordinates_near_pole | Warning | Semantic |
decreasing_shape_dist
code of time_sequence | Error | Semantic |
decreasing_time
code of time_sequence | Error | Semantic |
degenerate_shape
code of shape_geometry | Warning | Semantic |
departure_before_arrival
code of time_sequence | Error | Semantic |
duplicate_coordinates | Warning | Semantic |
duplicate_entity_id | Warning | Realtime |
duplicate_feature_id | Error | Semantic |
duplicate_key | Error | Semantic |
duplicate_shape_point
code of shape_geometry | Warning | Semantic |
duplicated_column | Error | Structural |
empty_column_name | Error | Structural |
empty_file | Error | Structural |
empty_row | Warning | Structural |
etalab_missing_contact | Warning | Semantic |
exception_date_out_of_range
code of calendar_dates_coherence | Warning | Semantic |
excessive_delay | Warning | Realtime |
expired_feed
code of feed_coverage | Warning | Semantic |
extended_route_type
code of route_type_semantics | Warning | Semantic |
fares_circular_transfer | Warning | Semantic |
fares_empty_area | Warning | Semantic |
fares_invalid_transfer_count | Error | Semantic |
fares_negative_amount | Error | Semantic |
fares_timeframe_overlap | Warning | Semantic |
fares_unused_product | Warning | Semantic |
fares_zero_amount | Warning | Semantic |
fares_zero_duration_limit | Error | Semantic |
feed_coverage | Warning | Semantic |
feed_expiring_soon
code of feed_coverage | Warning | Semantic |
feed_not_fresh | Warning | Realtime |
field_definition_agency | Error | Semantic |
field_definition_attributions | Error | Semantic |
field_definition_booking_rules | Error | Semantic |
field_definition_fares_v2 | Error | Semantic |
field_definition_feed_info | Warning | Semantic |
field_definition_pathways | Error | Semantic |
field_definition_routes | Error | Semantic |
field_definition_stop_times | Error | Semantic |
field_definition_stop_times_flex | Error | Semantic |
field_definition_stops | Error | Semantic |
field_definition_transfers | Error | Semantic |
field_definition_translations | Error | Semantic |
field_definition_trips | Error | Semantic |
field_type_validator | Error | Semantic |
first_stop_times_differ
code of time_sequence | Error | Semantic |
fk_attributions_agency_id
code of fk_attributions_refs | Error | Semantic |
fk_attributions_refs | Error | Semantic |
fk_attributions_route_id
code of fk_attributions_refs | Error | Semantic |
fk_attributions_trip_id
code of fk_attributions_refs | Error | Semantic |
fk_fare_attributes_agency_id | Error | Semantic |
fk_fare_leg_join_rules_from_network_id | Error | Semantic |
fk_fare_leg_join_rules_from_stop_id | Error | Semantic |
fk_fare_leg_join_rules_to_network_id | Error | Semantic |
fk_fare_leg_join_rules_to_stop_id | Error | Semantic |
fk_fare_leg_rules_fare_product_id | Error | Semantic |
fk_fare_leg_rules_from_area_id | Error | Semantic |
fk_fare_leg_rules_from_timeframe_group_id | Error | Semantic |
fk_fare_leg_rules_network_id | Error | Semantic |
fk_fare_leg_rules_to_area_id | Error | Semantic |
fk_fare_leg_rules_to_timeframe_group_id | Error | Semantic |
fk_fare_products_fare_media_id | Error | Semantic |
fk_fare_products_rider_category_id | Error | Semantic |
fk_fare_rules_contains_id
code of fk_fare_rules_zones | Error | Semantic |
fk_fare_rules_destination_id
code of fk_fare_rules_zones | Error | Semantic |
fk_fare_rules_fare_id | Error | Semantic |
fk_fare_rules_origin_id
code of fk_fare_rules_zones | Error | Semantic |
fk_fare_rules_route_id | Error | Semantic |
fk_fare_rules_zones | Error | Semantic |
fk_fare_transfer_rules_fare_product_id | Error | Semantic |
fk_fare_transfer_rules_from_leg_group_id | Error | Semantic |
fk_fare_transfer_rules_to_leg_group_id | Error | Semantic |
fk_frequencies_trip_id | Error | Semantic |
fk_pathways_from_stop_id
code of fk_pathways_stops | Error | Semantic |
fk_pathways_stops | Error | Semantic |
fk_pathways_to_stop_id
code of fk_pathways_stops | Error | Semantic |
fk_route_networks_network_id | Error | Semantic |
fk_route_networks_route_id | Error | Semantic |
fk_routes_agency_id | Error | Semantic |
fk_stop_areas_area_id | Error | Semantic |
fk_stop_areas_stop_id | Error | Semantic |
fk_stop_times_stop_id | Error | Semantic |
fk_stop_times_trip_id | Error | Semantic |
fk_stops_level_id | Error | Semantic |
fk_stops_parent_station | Error | Semantic |
fk_timeframes_service_id | Error | Semantic |
fk_transfers_from_route_id | Error | Semantic |
fk_transfers_from_stop_id | Error | Semantic |
fk_transfers_from_trip_id | Error | Semantic |
fk_transfers_to_route_id | Error | Semantic |
fk_transfers_to_stop_id | Error | Semantic |
fk_transfers_to_trip_id | Error | Semantic |
fk_translations_record | Error | Semantic |
fk_translations_record_id
code of fk_translations_record | Error | Semantic |
fk_translations_record_sub_id
code of fk_translations_record | Error | Semantic |
fk_trips_route_id | Error | Semantic |
fk_trips_service_id | Error | Semantic |
fk_trips_shape_id | Error | Semantic |
flex_empty_location_group | Warning | Semantic |
flex_incomplete_prior_notice_last | Warning | Semantic |
flex_inconsistent_booking | Warning | Semantic |
flex_insufficient_service_coverage | Warning | Semantic |
flex_invalid_duration_factor | Error | Semantic |
flex_invalid_prior_notice | Error | Semantic |
flex_invalid_prior_notice_range | Error | Semantic |
flex_invalid_window | Error | Semantic |
flex_unsafe_duration | Warning | Semantic |
forbidden_content
code of control_character | Error | Structural |
foreign_key_violation | Error | Semantic |
frequencies_coherence | Error | Semantic |
future_timestamp | Warning | Realtime |
google_coordinates_in_stop_name | Warning | Semantic |
google_identical_route_colors | Warning | Semantic |
inactive_service
code of calendar_ranges | Error | Semantic |
invalid_character
code of text_validator | Warning | Semantic |
invalid_color
code of field_type_validator | Error | Semantic |
invalid_currency
code of field_type_validator | Error | Semantic |
invalid_date not disableable | Error | Parse |
invalid_delimiter | Error | Structural |
invalid_email
code of field_type_validator | Error | Semantic |
invalid_encoding | Error | Structural |
invalid_float not disableable | Error | Parse |
invalid_geojson not disableable | Error | Parse |
invalid_headway
code of frequencies_coherence | Error | Semantic |
invalid_inner_quotes
code of invalid_quoting | Error | Structural |
invalid_input_files_in_subfolder | Error | Structural |
invalid_integer not disableable | Error | Parse |
invalid_language_code
code of field_type_validator | Error | Semantic |
invalid_parent_type | Error | Semantic |
invalid_phone_number
code of field_type_validator | Error | Semantic |
invalid_quoting | Error | Structural |
invalid_row_encoding not disableable | Error | Parse |
invalid_row_length | Error | Structural |
invalid_time not disableable | Error | Parse |
invalid_time_range
code of frequencies_coherence | Error | Semantic |
invalid_timezone
code of field_type_validator | Error | Semantic |
invalid_traversal_time
code of pathway_validation | Error | Semantic |
invalid_url
code of field_type_validator | Error | Semantic |
inverted_date_range
code of calendar_ranges | Error | Semantic |
low_trip_activity | Warning | Semantic |
missing_agency_email | Info | Semantic |
missing_bikes_info | Info | Semantic |
missing_calendar_and_calendar_date_files | Error | Structural |
missing_direction_id | Warning | Semantic |
missing_feature_id | Error | Semantic |
missing_header | Error | Structural |
missing_or_zero_timestamp | Error | Realtime |
missing_recommended_file | Warning | Structural |
missing_recommended_property | Warning | Semantic |
missing_required_column | Error | Structural |
missing_required_field not disableable | Error | Parse |
missing_required_file | Error | Structural |
missing_route_colors | Info | Semantic |
missing_schedule_relationship | Warning | Realtime |
missing_stop_sequence_for_repeated_stop | Error | Realtime |
missing_vehicle_id | Warning | Realtime |
missing_wheelchair_info | Warning | Semantic |
mixed_case_recommended_field
code of text_validator | Warning | Semantic |
new_line_in_value | Error | Structural |
non_ascii_or_non_printable_char
code of text_validator | Warning | Semantic |
non_increasing_stop_sequence
code of time_sequence | Error | Semantic |
number_out_of_range | Error | Semantic |
one_way_pathway_without_return
code of pathway_validation | Error | Semantic |
otp_missing_feed_version | Warning | Semantic |
otp_trip_too_few_stops | Error | Semantic |
overlapping_frequencies
code of frequencies_coherence | Error | Semantic |
pathway_validation | Error | Semantic |
polygon_too_few_points | Error | Semantic |
position_outside_feed_bounds | Warning | Realtime |
redundant_route_name | Warning | Semantic |
route_short_name_too_long | Warning | Semantic |
route_type_semantics | Warning | Semantic |
rt_missing_header | Error | Realtime |
rt_route_not_in_schedule | Error | Realtime |
rt_stop_not_in_schedule | Error | Realtime |
rt_stop_wrong_location_type | Error | Realtime |
rt_trip_not_in_schedule | Error | Realtime |
self_intersecting_polygon | Warning | Semantic |
self_transfer
code of transfer_validation | Error | Semantic |
service_never_active
code of calendar_dates_coherence | Warning | Semantic |
shape_dist_traveled_incoherent
code of shape_geometry | Warning | Semantic |
shape_geometry | Warning | Semantic |
shape_points_too_close
code of shape_geometry | Warning | Semantic |
short_feed_coverage
code of feed_coverage | Warning | Semantic |
speed_validation | Warning | Semantic |
start_time_mismatch_first_arrival | Error | Realtime |
station_without_entrance_pathway
code of pathway_validation | Error | Semantic |
stop_name_all_caps | Warning | Semantic |
stop_time_sequence_unsorted | Error | Realtime |
stop_time_update_times_not_increasing | Error | Realtime |
stop_too_far_from_shape | Warning | Semantic |
superfluous_whitespace | Warning | Structural |
text_validator | Warning | Semantic |
time_sequence | Error | Semantic |
too_many_rows | Error | Structural |
transfer_distance_suspicious
code of transfer_validation | Error | Semantic |
transfer_distance_too_large
code of transfer_validation | Error | Semantic |
transfer_validation | Error | Semantic |
translations_unknown_field | Warning | Semantic |
translations_unknown_table | Error | Semantic |
trip_too_long
code of time_sequence | Error | Semantic |
unclosed_polygon | Error | Semantic |
unexpected_enum_value not disableable | Warning | Parse |
unknown_column | Info | Structural |
unknown_file | Info | Structural |
unknown_route_type
code of route_type_semantics | Warning | Semantic |
unordered_stop_times | Error | Realtime |
unreadable_file not disableable | Error | Parse |
unrealistic_speed
code of speed_validation | Warning | Semantic |
unsupported_geometry_type | Error | Semantic |
unsupported_version | Warning | Realtime |
unused_agency | Warning | Semantic |
unused_fare | Warning | Semantic |
unused_route | Warning | Semantic |
unused_service | Warning | Semantic |
unused_shape | Warning | Semantic |
unused_station | Warning | Semantic |
unused_stop | Warning | Semantic |
zero_area_polygon | Warning | Semantic |
zero_speed
code of speed_validation | Warning | Semantic |
zero_transfer_time
code of transfer_validation | Error | Semantic |
Comment cette table est construite
Section intitulée « Comment cette table est construite »Les règles sont dumpées depuis le registre Rust avec gapline rules list --format json :
gapline rules list --format json -o validation-rules.jsonLe JSON est committé dans le repo de docs et doit être régénéré avec la commande ci-dessus à chaque release. Un test de la suite gapline (rules_list_matches_disable_rule_accepted_ids) garantit que la liste et les IDs acceptés par --disable-rule restent identiques.
Politique de sévérité
Section intitulée « Politique de sévérité »- Error — le flux n’est pas conforme. Les consommateurs en aval rejettent les lignes fautives.
- Warning — le flux est conforme mais probablement cassé. À investiguer.
- Info — suggestion de bonne pratique.
Voir concepts / sévérités pour la politique complète et comment --min-severity promeut les avertissements en bloquants.
- Structural — la forme du flux : fichiers requis, parsabilité CSV, présence d’en-têtes, validité des colonnes. Tourne en premier ; rien en aval n’est pertinent si ces règles échouent.
- Semantic — tout ce qui demande le modèle de données parsé : valeurs de champs, clés étrangères, cohérence des horaires, bonnes pratiques.
- Realtime — règles du flux GTFS-Realtime.
- Parse — codes produits au parsing des valeurs (
invalid_integer,invalid_float,invalid_date,invalid_time,unexpected_enum_value,missing_required_field,invalid_geojson). Toujours émis, non désactivables ; seul--min-severitypeut masquer celui de niveau warning.
Voir aussi
Section intitulée « Voir aussi »gapline rules list— énumérer les règles d’un build local.gapline validate— désactiver une règle via--disable-rule.- Concepts / Sévérités — quand promouvoir un warning.