Closed vpaturet closed 4 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 68.47%. Comparing base (
06a7e8c
) to head (e7e38e4
). Report is 1 commits behind head on dev-2.x.:exclamation: Current head e7e38e4 differs from pull request most recent head d84e7f5
Please upload reports for the commit d84e7f5 to get more accurate results.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@lassetyr The fix introduces a systematic validation of scheduled data for extra journeys: https://github.com/opentripplanner/OpenTripPlanner/pull/5867/commits/a71c690e8d323a9a77cfd8f1cb244744fd9fb73c (there is only one commit in this PR, it should be rebased when #5865 is merged)
This is likely to have little impact on performance, but may lead to more rejected messages. Is this acceptable?
I do not see any reason why we/OTP should accept invalid data, so in my opinion, this is acceptable.
Summary
As detailed in #5866, some combinations of SIRI messages lead to the creation of invalid trips where passing times do not increase along the journey. This PR aims to fix one such scenario where:
The canceled trip can then be queried thanks to the API parameter
includeRealtimeCancellations=true
The proposed fix is to validate the scheduled data in step 2 and rejects messages that contain invalid scheduled data.
Issue
Closes #5866
Unit tests
Added unit test