Skip to content
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

Extract prerelease/build information from package semver #6839

Merged

Conversation

mjjbell
Copy link
Member

@mjjbell mjjbell commented Mar 24, 2024

Issue

Currently we only extract the major.minor.patch identifiers from the semver label stored in package.json.

This leads to version information in executables incorrectly reporting a release version is running on prereleases and special builds.

This commit is a quickfix to extract this information and report it in version strings.

$ ./osrm-extract --version
v5.28.0-unreleased

$ ./osrm-routed ../../osrm-data/greater-london/greater-london-latest.osm.pbf 
[2024-03-24T14:17:30.149149270] [info] starting up engines, v5.28.0-unreleased
[2024-03-24T14:17:30.149236196] [info] Threads: 12
[2024-03-24T14:17:30.149250498] [info] IP address: 0.0.0.0
[2024-03-24T14:17:30.149260265] [info] IP port: 5000
[2024-03-24T14:17:30.149269842] [info] Keepalive timeout: 5
...

CMake regex parsing is not sophisticated enough to handle the full semver regex, so we might need to explore other CMake modules if we want to strictly parse the label.

Tasklist

Requirements / Relations

Fixes #6767

Currently we only extract the major.minor.patch identifiers from
the semver label stored in package.json.

This leads to version information in executables to incorrectly
report a release version is running on prereleases and special builds.

This commit is a quickfix to extract this information and report it
in version strings.

CMake regex parsing is not sophisticated enough to handle the full semver
regex, so we might need to explore other CMake modules if we want to
strictly parse the label.
Copy link
Collaborator

@DennisOSRM DennisOSRM left a comment

Choose a reason for hiding this comment

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

👍🏽

@mjjbell mjjbell force-pushed the mbell/extract_prerelease_build_label branch from 1d1be16 to 83671f3 Compare March 24, 2024 16:33
@mjjbell mjjbell merged commit d0e3e2a into Project-OSRM:master Mar 24, 2024
20 checks passed
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.

Docker not up to date
2 participants