-
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
Publicly expose binaries to Node.js bindings, resolves #4377 #4386
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.
Did the package-lock.json
file need to be updated to support something in particular, or was that just a general update?
After speaking with some folks, the usual strategy seems to be:
- Update
package-lock.json
if you change a dependency inpackage.json
- Update
package-lock.json
if you need to update a dependency somewhere in the tree - Otherwise, it can generally be left alone.
If there's no explicit reason to update the lockfile here, would you mind reverting that part of this change?
Side note: we're building using yarn
(not npm
) on Travis, but we're not maintaining yarn
's duplicate yarn.lock
file. Until we have a good consistent strategy for maintaining these files, I suggest we don't clutter our PRs with the noise that the auto-generated file diff creates.
@@ -1,6 +1,6 @@ | |||
{ | |||
"name": "osrm", | |||
"version": "5.11.0", | |||
"version": "5.11.0-latest.1", | |||
"private": false, |
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.
Does this PR need to bump the version number?
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.
No I don't think so I just noticed the version is 5.11.0 and we want a version string on master not matching a release we want to do in the future (if I understand it correctly?). This probably needs a section in the releasing.md, to bump the version string after a release immediately on master (?)
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.
Yeah bumping after release to {MAJOR}.{MINOR+1}.0-latest.1
should be the best-practice.
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 will add this to the releasing docs.
What is unclear to me is file compatibility between releases. We bump the package json version but not the CMakeLists version. This results in:
- either we bump to 5.11.0 in CMakeLists immediately after we released 5.10, which would result in the actual 5.11.0 release being compatible with all datasets generated right after we cut 5.10, or
- we only bump to 5.11.0 in CMakeLists right before we publish the proper 5.11.0 release, which would result in all datasets generated before being compatible with 5.10.
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.
How about setting versions on master
to 0.0.0
(both package.json and CMakeLists.txt) always, and only modifying the version field on release branches?
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.
Then all master datasets will be compatible with each other
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.
But we have that problem already - we often merge breaking data changes to master
and we don't bump the version number.
IMO the biggest concern with "master datasets are all compatible" would be bizzaro tickets being opened by folks not realizing that they're trying to use old data, creating weird error situations and undefined behaviour that's hard to debug. You're right, I don't think we want to create that kind of trouble for ourselves.
The old approach of checksumming the critical IO files was semi-workable, as long as we can capture all code that affects the file format in the checksum value. I haven't looked at our re-factoring for a while, are we closer, or further away from being able to automatically detect file compatibility using that approach?
Unfortunately, I think we need to roll this back. The problem is that the
i.e. I thought that maybe we could fix this by moving the call to The Mapnik project gets around this issue by bundling wrapper scripts as the binaries destined for We should do something similar (ugly as it is). I'll open a ticket to describe what needs to be done, but for now, I'm going to revert this change to un-block the 5.11 release. |
For #4377:
now puts osrm binaries in the right place, so users don't have to fiddle with internal paths. After
npm link
you can just callosrm-extract
; it will be in yourPATH
.cc @maning @srividyacb