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

“Error: Could not locate the bindings file” #525

Closed
migurski opened this issue Apr 25, 2016 · 7 comments
Closed

“Error: Could not locate the bindings file” #525

migurski opened this issue Apr 25, 2016 · 7 comments

Comments

@migurski
Copy link

I’m taking the API for a spin on Ubuntu 16.04. After installing all dependencies with npm install, I find that npm test works but npm start fails. Error output is below; Node is at 4.2.6 and NPM is at 3.5.2 on Ubuntu 16.04.

> pelias-api@2.2.0 start /tmp/api
> node index.js

usage: cannot find pre-compiled binary for: linux/x64/v4.2.6
usage: failed loading provider `linux`
/tmp/api/node_modules/bindings/bindings.js:91
  throw err
  ^

Error: Could not locate the bindings file. Tried:
 → /tmp/api/node_modules/memwatch-next/build/memwatch.node
 → /tmp/api/node_modules/memwatch-next/build/Debug/memwatch.node
 → /tmp/api/node_modules/memwatch-next/build/Release/memwatch.node
 → /tmp/api/node_modules/memwatch-next/out/Debug/memwatch.node
 → /tmp/api/node_modules/memwatch-next/Debug/memwatch.node
 → /tmp/api/node_modules/memwatch-next/out/Release/memwatch.node
 → /tmp/api/node_modules/memwatch-next/Release/memwatch.node
 → /tmp/api/node_modules/memwatch-next/build/default/memwatch.node
 → /tmp/api/node_modules/memwatch-next/compiled/4.2.6/linux/x64/memwatch.node
    at bindings (/tmp/api/node_modules/bindings/bindings.js:88:9)
    at Object.<anonymous> (/tmp/api/node_modules/memwatch-next/include.js:2:28)
    at Module._compile (module.js:410:26)
    at Object.Module._extensions..js (module.js:417:10)
    at Module.load (module.js:344:32)
    at Function.Module._load (module.js:301:12)
    at Module.require (module.js:354:17)
    at require (internal/module.js:12:17)
    at Object.<anonymous> (/tmp/api/node_modules/cluster2/lib/process.js:30:16)
    at Module._compile (module.js:410:26)

npm ERR! Linux 4.4.0-21-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "start"
npm ERR! node v4.2.6
npm ERR! npm  v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! pelias-api@2.2.0 start: `node index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the pelias-api@2.2.0 start script 'node index.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the pelias-api package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node index.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs pelias-api
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls pelias-api
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /tmp/api/npm-debug.log
@orangejulius
Copy link
Member

Hmm. I've never seen this error before. Even google isn't particularly helpful. If you have a chance, can you try a similar process on Ubuntu 15? If not I'll try to test things out on an Ubuntu 16 VM.

@migurski
Copy link
Author

migurski commented Apr 26, 2016

On Ubuntu 15.10, the versions are Node 0.10.25 and NPM 1.4.21. Crazy to try with such early versions of each?

@orangejulius
Copy link
Member

Nope. Everyone in the Node world wants to rid themselves of 0.10, but in fact it's Ubuntu that is really holding people back, so most projects still support 0.10

@migurski
Copy link
Author

Interesting. I saw a bunch of this go by:

npm WARN … wanted: {"node":">=0.10.40"} (current: {"node":"0.10.25","npm":"1.4.21"})

…but both npm test and npm start appear to work! So that’s nice, but doesn't exactly answer the question of how make this go on a long-term support edition of Ubuntu.

🕝

Of course, now that I’m trying it all again on 16.04, npm start works just fine. 😐

@orangejulius
Copy link
Member

Those particular warnings are ok. In fact most NPM warnings are ok, although you can feel free to report them and we'll try to fix them. Warnings exist for a reason after all.

If it works, then that's great. I'll test it out in the future on a VM (or possibly when I upgrade my machine to ubuntu 16), and as more issues arise we'll tackle them.

@migurski
Copy link
Author

Thanks. I’m going to close this since it’s apparently fine now.

@tigerlily-he
Copy link
Contributor

This error can come up if Libpostal was installed after you did npm install for the API. The solution is to delete and reinstall node modules for the API: rm -rf node_modules && npm install.

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

No branches or pull requests

3 participants