Skip to content
This repository has been archived by the owner on Jan 24, 2022. It is now read-only.

Install fails because of [email protected] in node 13.2.0 #1419

Closed
vmandal opened this issue Feb 4, 2020 · 10 comments
Closed

Install fails because of [email protected] in node 13.2.0 #1419

vmandal opened this issue Feb 4, 2020 · 10 comments
Assignees
Labels

Comments

@vmandal
Copy link

vmandal commented Feb 4, 2020

404 error here

node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.23.3/node-v79-linux-x64-glibc.tar.gz

node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v79 ABI, glibc) (falling back to source compile with node-gyp)

so it tries to build it and than it has lot of error

/home/vikram/.cache/node-gyp/13.2.0/include/node/v8.h:1576:58: error: ‘deprecated’ attribute directive ignored [-Werror=attributes]
Local<Value> export_value);
...
gyp ERR! stack Error: `make` failed with exit code: 2
...

..
many more such errors

@hannounfouad
Copy link

I have an even worse message when I install.

CXX(target) Release/obj.target/grpc_node/ext/call.o
../ext/call.cc:104:53: error: no matching member function for call to 'Get'
Local current_key(Nan::To(keys->Get(i)).ToLocalChecked());
~~~~~~^~~
/Users/fouad.hannoun/Library/Caches/node-gyp/13.6.0/include/node/v8.h:3594:43: note:
candidate function not viable: requires 2 arguments, but 1 was provided
V8_WARN_UNUSED_RESULT MaybeLocal Get(Local context,
^
/Users/fouad.hannoun/Library/Caches/node-gyp/13.6.0/include/node/v8.h:3597:43: note:
candidate function not viable: requires 2 arguments, but 1 was provided
V8_WARN_UNUSED_RESULT MaybeLocal Get(Local context,
^
../ext/call.cc:681:27: error: no matching member function for call to 'Get'
if (!op->ParseOp(obj->Get(type), &ops[i])) {
~~~~~^~~
/Users/fouad.hannoun/Library/Caches/node-gyp/13.6.0/include/node/v8.h:3594:43: note:
candidate function not viable: requires 2 arguments, but 1 was provided
V8_WARN_UNUSED_RESULT MaybeLocal Get(Local context,
^
/Users/fouad.hannoun/Library/Caches/node-gyp/13.6.0/include/node/v8.h:3597:43: note:
candidate function not viable: requires 2 arguments, but 1 was provided
V8_WARN_UNUSED_RESULT MaybeLocal Get(Local context,
^
2 errors generated.
make: *** [Release/obj.target/grpc_node/ext/call.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (events.js:321:20)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
gyp ERR! System Darwin 19.2.0
gyp ERR! command "/usr/local/Cellar/node/13.6.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/src/node/extension_binary/node-v79-darwin-x64-unknown/grpc_node.node" "--module_name=grpc_node" "--module_path=/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/src/node/extension_binary/node-v79-darwin-x64-unknown" "--napi_version=5" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v79"
gyp ERR! cwd /usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc
gyp ERR! node -v v13.6.0
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/Cellar/node/13.6.0/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/src/node/extension_binary/node-v79-darwin-x64-unknown/grpc_node.node --module_name=grpc_node --module_path=/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/src/node/extension_binary/node-v79-darwin-x64-unknown --napi_version=5 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v79' (1)
node-pre-gyp ERR! stack at ChildProcess. (/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:321:20)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1028:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
node-pre-gyp ERR! System Darwin 19.2.0
node-pre-gyp ERR! command "/usr/local/Cellar/node/13.6.0/bin/node" "/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd /usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc
node-pre-gyp ERR! node -v v13.6.0
node-pre-gyp ERR! node-pre-gyp -v v0.13.0
node-pre-gyp ERR! not ok
Failed to execute '/usr/local/Cellar/node/13.6.0/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/src/node/extension_binary/node-v79-darwin-x64-unknown/grpc_node.node --module_name=grpc_node --module_path=/usr/local/lib/node_modules/@openzeppelin/cli/node_modules/grpc/src/node/extension_binary/node-v79-darwin-x64-unknown --napi_version=5 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v79' (1)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: node-pre-gyp install --fallback-to-build --library=static_library
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /Users/fouad.hannoun/.npm/_logs/2020-02-04T08_36_13_327Z-debug.log

@abcoathup
Copy link
Contributor

Hi @vmandal Thanks for reporting.

I recommend using an earlier version of node. I currently use node 10.

I get the same issue:

gyp ERR! cwd /c/Users/andre/Documents/projects/forum/thirteen/node_modules/solc-wrapper/node_modules/keccak
gyp ERR! node -v v13.6.0
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] rebuild: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] rebuild script.
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.23.3/node-v79-linux-x64-glibc.tar.gz
node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v79 ABI, glibc) (falling back to source compile with node-gyp)

@abcoathup
Copy link
Contributor

grpc/grpc-node#1216 (comment)
Support for Node 13 was added in grpc 1.24.2.

@vmandal
Copy link
Author

vmandal commented Feb 4, 2020

[email protected] must have been defined as a dependency in some package.
Installing grpc 1.24.2 before installing CLI did not help

I found
openzeppelin-labs has "grpc": "1.23.3", dependency
https://github.com/OpenZeppelin/openzeppelin-labs/blob/master/contracts-upgradeability-transpiler/package-lock.json

OpenZeppelin / starter-kit also has this dependency
https://github.com/OpenZeppelin/starter-kit/blob/master/package-lock.json

I do not know which package is asking for [email protected] while installing OpenZeppelin CLI

Is there a work around.
Updated:
CLI installed fine in node v10

@abcoathup
Copy link
Contributor

The recommended workaround is to use an earlier version of node. I currently use node 10.

@frangio
Copy link
Contributor

frangio commented Feb 5, 2020

We should also support Node 12. I was unable to install the CLI on Node 12 though. Can someone else try and let us know in #1371?

spalladino added a commit that referenced this issue Feb 11, 2020
Updates grpc transitive dependency, which was causing install issues in node 13

Fixes #1419
spalladino added a commit that referenced this issue Feb 11, 2020
Updates grpc transitive dependency, which was causing install issues in node 13

Fixes #1419
@spalladino
Copy link
Contributor

Hey @vmandal! We have just released 2.7.1 with node 13 support. Please check it out and let us know if it works for you!

@abcoathup abcoathup reopened this Feb 18, 2020
@abcoathup
Copy link
Contributor

npm i @openzeppelin/cli@rc fails to install on node v13.8.0 (whilst CLI 2.7.1 does install)

Pre-built binaries not found:

node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.23.3/node-v79-linux-x64-glibc.tar.gz
node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v79 ABI, glibc) (falling back to source compile with node-gyp)

Then fails on building:

gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/home/abcoathup/.nvm/versions/node/v13.8.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:321:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
gyp ERR! System Linux 4.4.0-18362-Microsoft
gyp ERR! command "/home/abcoathup/.nvm/versions/node/v13.8.0/bin/node" "/home/abcoathup/.nvm/versions/node/v13.8.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/c/Users/andre/Documents/projects/forum/rc13/node_modules/grpc/src/node/extension_binary/node-v79-linux-x64-glibc/grpc_node.node" "--module_name=grpc_node" "--module_path=/c/Users/andre/Documents/projects/forum/rc13/node_modules/grpc/src/node/extension_binary/node-v79-linux-x64-glibc" "--napi_version=5" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v79"
gyp ERR! cwd /c/Users/andre/Documents/projects/forum/rc13/node_modules/grpc
gyp ERR! node -v v13.8.0
gyp ERR! node-gyp -v v5.0.7
gyp ERR! not ok
node-pre-gyp ERR! build error

@spalladino
Copy link
Contributor

My bad, I fixed this in 2.7.1, but backported it to master after 2.8.0-rc.0 was released. It should be fixed in the next 2.8 release.

@frangio frangio self-assigned this Feb 18, 2020
frangio pushed a commit that referenced this issue Feb 18, 2020
Updates grpc transitive dependency, which was causing install issues in node 13

Fixes #1419

(cherry picked from commit 55b3d65)
@frangio
Copy link
Contributor

frangio commented Feb 18, 2020

Ported to 2.8 in 6600961. Will be in the next release candidate.

@frangio frangio closed this as completed Feb 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants