Skip to content

feat: validate consecutive stop times with same time - #2185

Open
mackenziereading19 wants to merge 1 commit into
MobilityData:masterfrom
mackenziereading19:178-consecutive-stop-times
Open

feat: validate consecutive stop times with same time#2185
mackenziereading19 wants to merge 1 commit into
MobilityData:masterfrom
mackenziereading19:178-consecutive-stop-times

Conversation

@mackenziereading19

Copy link
Copy Markdown

Summary

Implements #178 by porting the historical Google Python validator check for trips with too many consecutive stop_times.txt rows sharing the same fully specified time.

The validator:

  • runs per trip_id using the existing grouped stop-time table architecture;
  • reports an INFO notice when a run contains more than five consecutive stop-time records with the same arrival/departure time;
  • preserves the historical Python validator semantics for intervening rows with a missing arrival or departure time, which may contribute to a potential run that is later confirmed by a fully specified row;
  • emits one notice per qualifying run with tripId, entityCount, and time.

Tests

Added focused regression coverage for:

  • exactly five matching stop times: no notice;
  • six matching stop times: notice;
  • run termination when the time changes;
  • qualifying run at end of trip;
  • historical missing-time behavior;
  • multiple qualifying runs in one trip;
  • independent evaluation of different trips.

Focused result: 7 passed.

Full :main:test result locally: 682 passed, 3 failed. The three failures are pre-existing Java 21 / Mockito environment failures (JsonReportSummaryGeneratorTest x2 and VersionResolverTest) and were reproduced independently on untouched baseline 21b27a4ac903bc2bc43d42a89bb3dbb47cc8921d.

Closes #178

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement trip consecutive stops verification (GTFS rule)

1 participant