-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pass flags into process_segment #6658
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not quite sure how to write an automated test for this. Maybe a profile that uses the flags information in a cucumber test?
Yes, take a look at https://github.com/Project-OSRM/osrm-backend/blob/master/features/options/extract/lua.feature and https://github.com/Project-OSRM/osrm-backend/blob/master/features/options/extract/turn_function.feature.
You could write a test that uses the flags within the profile's process_segment
function and confirm you get the expected result.
527f823
to
b208aa8
Compare
I'm having some trouble getting the Cucumber tests running to finish this, which seems to have to do the node OSRM library. It looks like it's trying to find it locally, failing, and then trying to grab it from github, which fails as well since it's a non-release version. Do I need to do something to build the Node.js bindings locally? |
Okay, I figured out the Cucumber tests and added a test that confirms that segment flags get passed through to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Please add a changelog entry.
Co-authored-by: Michael Bell <[email protected]>
7953b62
to
64b6635
Compare
@mjjbell I added the changelog entry and rebased to avoid merge conflicts in changelog. Thanks! |
Windows build error
Issue
This partially addresses #6145, by making the extractor edge flags available to
process_segment
assegment.flags
. This allows accessing road classification, start point, etc. inprocess_segment
. I'm using it by tagging bridges/tunnels as non-startpoints and then not applying elevation weighting to them since they are flat (ish) where I am but often cross deep valleys.I'm not quite sure how to write an automated test for this. Maybe a profile that uses the flags information in a cucumber test?
Tasklist
Requirements / Relations
Link any requirements here. Other pull requests this PR is based on?