Skip to content

Add 'boardCost' parameter for cars#6413

Merged
optionsome merged 5 commits into
opentripplanner:dev-2.xfrom
HSLdevcom:car-transit-preferences
Feb 3, 2025
Merged

Add 'boardCost' parameter for cars#6413
optionsome merged 5 commits into
opentripplanner:dev-2.xfrom
HSLdevcom:car-transit-preferences

Conversation

@VillePihlava

Copy link
Copy Markdown
Contributor

Summary

This PR adds a boardCost parameter for cars to the router config. This is similar to what can currently be found for walking and cycling. This can improve car transit routing results.

Issue

This is a follow-up PR related to issue #5875

Unit tests

I added more checks to existing unit tests related to the additions.

Documentation

Changes to RouteRequest.md and RouterConfiguration.md.

@VillePihlava VillePihlava requested a review from a team as a code owner January 30, 2025 11:48
@codecov

codecov Bot commented Jan 30, 2025

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 73.07692% with 7 lines in your changes missing coverage. Please review.

Project coverage is 69.84%. Comparing base (c8fbf02) to head (87507f3).
Report is 46 commits behind head on dev-2.x.

Files with missing lines Patch % Lines
...ansit/mappers/GeneralizedCostParametersMapper.java 25.00% 1 Missing and 2 partials ⚠️
...ntripplanner/apis/gtfs/generated/GraphQLTypes.java 50.00% 2 Missing ⚠️
...routing/api/request/preference/CarPreferences.java 77.77% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             dev-2.x    #6413   +/-   ##
==========================================
  Coverage      69.84%   69.84%           
  Complexity     18125    18125           
==========================================
  Files           2069     2069           
  Lines          77268    77293   +25     
  Branches        7855     7858    +3     
==========================================
+ Hits           53965    53983   +18     
- Misses         20546    20551    +5     
- Partials        2757     2759    +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@VillePihlava VillePihlava changed the title Add boardCost parameter for cars to the router config Add 'boardCost' parameter for cars to the router config Jan 30, 2025

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove duplicate imports

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@optionsome optionsome changed the title Add 'boardCost' parameter for cars to the router config Add 'boardCost' parameter for cars Jan 30, 2025
@optionsome optionsome added +Config Change This PR might require the configuration to be updated. !Improvement A functional improvement or micro feature +Bump Serialization Id Add this label if you want the serialization id automatically bumped after merging the PR labels Jan 30, 2025
@optionsome optionsome added this to the 2.7 (next release) milestone Jan 30, 2025

@leonardehrenfried leonardehrenfried left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is clean and has good documentation. 👍

If you fulfil Joel's requests, this is good to merge.

@optionsome optionsome merged commit f19596c into opentripplanner:dev-2.x Feb 3, 2025
@optionsome optionsome deleted the car-transit-preferences branch February 3, 2025 15:21
t2gran pushed a commit that referenced this pull request Feb 3, 2025
t2gran pushed a commit that referenced this pull request Feb 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

+Bump Serialization Id Add this label if you want the serialization id automatically bumped after merging the PR +Config Change This PR might require the configuration to be updated. !Improvement A functional improvement or micro feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants