Expose algorithms option in node bindings and integrate new toolchain#3834
Expose algorithms option in node bindings and integrate new toolchain#3834
Conversation
76b6626 to
598219b
Compare
c850d90 to
24781e7
Compare
24781e7 to
ce5afb7
Compare
fdfe32b to
abaa474
Compare
| env: | ||
| global: | ||
| - secure: "hk+32aXXF5t1ApaM2Wjqooz3dx1si907L87WRMkO47WlpJmUUU/Ye+MJk9sViH8MdhOcceocVAmdYl5/WFWOIbDWNlBya9QvXDZyIu2KIre/0QyOCTZbrsif8paBXKIO5O/R4OTvIZ8rvWZsadBdmAT9GSbDhih6FzqXAEgeIYQ=" | ||
| - secure: "VE+cFkseFwW4jK6XwkP0yW3h4DixPJ8+Eb3yKcchGZ5iIJxlZ/8i1vKHYxadgPRwSYwPSB14tF70xj2OmiT2keGzZUfphmPXinBaLEhYk+Bde+GZZkoSl5ND109I/LcyNr0nG9dDgtV6pkvFchgchpyP9JnVOOS0+crEZlAz0RE=" |
There was a problem hiding this comment.
Where did you get those from and how are they getting used? for node pre gyp publishing / aws credentials?
There was a problem hiding this comment.
Yup they set node_pre_gyp_{secretKey,KeyId}.
| - /^v\d+\.\d+(\.\d+)?(-\S*)?$/ | ||
|
|
||
| cache: | ||
| yarn: true |
There was a problem hiding this comment.
Ah I guess this is https://blog.travis-ci.com/2016-11-21-travis-ci-now-supports-yarn - is yarn worth it locally?
There was a problem hiding this comment.
Yeah factor 3-5 faster then npm.
| - popd | ||
| - npm run build-api-docs | ||
| # building docs only works with npm3+ not with yarn or npm2 | ||
| #- yarn run docs |
There was a problem hiding this comment.
Why? And can't we just use npm here, then?
There was a problem hiding this comment.
This needs fixes in the docs tool. I don't see the point of building the docs for every build job. It almost takes a minute and would block us from using a sensible package manager like yarn.
docs/releasing.md
Outdated
| 7. Use `npm run build-api-docs` to generate the API documentation. Copy `build/docs/*` to `https://github.com/Project-OSRM/project-osrm.github.com` in the `docs/vN.N.N/api` directory | ||
| 8. Push tags and commits: `git push; git push --tags` | ||
| 9. If not a release-candidate: Write a mailing-list post to [email protected] to announce the release | ||
| 10. Wait until the travis build has been complated and check if the node binaries were published by doing: |
| { | ||
| Nan::ThrowError("algorithm option must be a string and one of 'CH', 'CoreCH', or 'MLD'."); | ||
| return engine_config_ptr(); | ||
| } |
There was a problem hiding this comment.
Hm, using the maybe returned from Get is fine this way? as in, this is the same as
maybe = Get();
if (!maybe) err;
?
There was a problem hiding this comment.
Hrm the docs say that the result from Object::Get is a MaybeLocal<> but that type does not have a operator->. For a Local<> calling operator-> is not safe since it would dereference a nullptr. So yes this would need a check.
| assert.ok(route.routes.length); | ||
| assert.ok(route.routes[0].geometry); | ||
| }); | ||
| }); |
There was a problem hiding this comment.
Urgh please merge into master asap, I'm already working on changing the tests to monaco
| if [[ "${TRAVIS_OS_NAME}" == "osx" ]]; then | ||
| export JOBS=$((`sysctl -n hw.ncpu` + 1)) | ||
| sudo mdutil -i off / | ||
| npm install -g yarn |
There was a problem hiding this comment.
We need to update the yarn.lock file every time we update package.config now?
There was a problem hiding this comment.
No it is updated automatically by yarn when you add a package using yarn add package. You will have to commit it though.
| "author": "", | ||
| "license": "ISC", | ||
| "author": "Project OSRM Team", | ||
| "license": "BSD 2-Clause", |
There was a problem hiding this comment.
guess ISC was wrong originally?
There was a problem hiding this comment.
Yes, this is just the default license and nobody changed it.
| @@ -0,0 +1,6179 @@ | |||
| # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. | |||
There was a problem hiding this comment.
Is it really necessary to commit the auto-generated file? Guess it is better to add it to .gitignore otherwise will be always local changes and conflicts.
There was a problem hiding this comment.
Yes this basically ensure that yarn resolves package versions the same for everyone installing osrm. One advantage of the yarn approach with the lock file is to enable caching, e.g. on Travis.
|
@daniel-j-h @oxidase hopefully I addressed all concerns. Let me know if this is good to merge. |
|
👍 |
oxidase
left a comment
There was a problem hiding this comment.
👍 just disappointed due to adding 6000 lines that is basically a job of a package manager.
Issue
Integrates algorithm flags into node bindings and bundles the new toolchain for MLD. This addresses #3846.
Tasklist
Requirements / Relations
Based on #3768.