Binary Download and Fallback to Build Fail on Node 8
I'm having problems installing idb-connector 1.1.3 with Node 8. If I try to install into a new project with no other dependencies I get this output:
#!
node-pre-gyp WARN Using needle for node-pre-gyp https download
node-pre-gyp WARN Pre-built binaries not installable for idb-connector@1.1.3 and node@8.12.0 (node-v57 ABI, unknown) (falling back to source compile with node-gyp)
node-pre-gyp WARN Hit error Remote end closed socket abruptly.
node-pre-gyp WARN Pre-built binaries not installable for idb-connector@1.1.3 and node@8.12.0 (node-v57 ABI, unknown) (falling back to source compile with node-gyp)
node-pre-gyp WARN Hit error bad download
Looks like 'needle' is unable to download the pre-built binary for some reason. Furthermore, the build fails when it falls back to trying to compile from source code with this:
#!
gyp: /home/drusso/idbtest/node_modules/idb-connector/build/config.gypi not found (cwd: /home/drusso/idbtest/node_modules/idb-connector) while reading includes of binding.gyp while trying to load binding.gyp
An interesting thing I noticed is that if I first install 'request' in my project, the idb-connector installation succeeds. Apparently 'node-pre-gyp' uses 'request' to do the download instead of 'needle";
#!
node-pre-gyp WARN Using request for node-pre-gyp https download
[idb-connector] Success: "/home/drusso/idbtest/node_modules/idb-connector/lib/binding/Release/node-v57-ibmi-ppc64/db2ia.node" is installed via remote
I'm getting this result with Node.js 8.12.0 on IBM i 7.2. The problem does not occur if I use Node.js 10.11.0 on the same system. In that case, 'needle' is able to download the binary and install w/o problems.
Is there some way to correct this problem for Node.js 8 so that it's not necessary to install 'request' first? Maybe request can be included in the idb-connector dependencies?
Comments (4)
-
Account Deactivated -
Account Deactivated I am afraid that it is a node-pre-gyp issue. So I updated the node-pre-gyp version to 0.11.0 in idb-connector v1.1.4. On my dev system, the 'needle' issue has gone. Would you try the new version?
-
Account Deactivated -
assigned issue to
-
assigned issue to
-
reporter - changed status to resolved
It works now, thanks!
- Log in to comment
@DavidRusso Yes, I am investigating this issue. It is weird. On my system, the error occurs if I install idb-connector to the global directory using node 8.12.0 -->
But it works fine if I simply use the 'local' install -->
While node 10 and previous node 8 versions have no such a issue.