hassio-addons/addon-node-red

Unable to install wmbus-client #431

MTrab posted onGitHub

Problem/Motivation

I can't install wmbus-client on a HassIO Node-Red. On a clean Node-Red docker on my Synology NAS I can install the palette without issues - hence I see it as an error in HassIO Node-Red Docker image

Expected behavior

Install node-red-contrib-wmbus-client

Actual behavior

Install stops with error.

26 Jan 22:41:02 - [warn] Installation of module node-red-contrib-wmbus-client failed:
26 Jan 22:41:02 - [warn] ------------------------------------------
26 Jan 22:41:02 - [warn] gyp ERR! build error 
gyp ERR! stack Error: not found: make
gyp ERR! stack     at getNotFoundError (/usr/lib/node_modules/npm/node_modules/which/which.js:13:12)
gyp ERR! stack     at F (/usr/lib/node_modules/npm/node_modules/which/which.js:68:19)
gyp ERR! stack     at E (/usr/lib/node_modules/npm/node_modules/which/which.js:80:29)
gyp ERR! stack     at /usr/lib/node_modules/npm/node_modules/which/which.js:89:16
gyp ERR! stack     at /usr/lib/node_modules/npm/node_modules/isexe/index.js:42:5
gyp ERR! stack     at /usr/lib/node_modules/npm/node_modules/isexe/mode.js:8:5
gyp ERR! stack     at FSReqCallback.oncomplete (fs.js:158:21)
gyp ERR! System Linux 4.9.0-11-amd64
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /config/node-red/node_modules/node-crc
gyp ERR! node -v v12.14.0
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok 
npm WARN multiple-select@1.5.2 requires a peer of jquery@1.9.1 - 3 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-crc@1.2.2 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the node-crc@1.2.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

Steps to reproduce

Install node-red-contrib-wmbus-client


Error: not found: make

You need to add the relevant packages to the config that are needed to build the node. For this particular error it would be: "system_packages": [ "make" ],

However I believe you will likely run into another error after that.

posted by sinclairpaul over 5 years ago

Yearh - that just makes it complain about missing cc, and there's no systempackage for cc :(

26 Jan 22:54:54 - [warn] Installation of module node-red-contrib-wmbus-client failed:
26 Jan 22:54:54 - [warn] ------------------------------------------
26 Jan 22:54:54 - [warn] make: cc: Command not found
make: *** [crc.target.mk:103: Release/obj.target/crc/src/crc.o] Error 127
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:210:5)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 4.9.0-11-amd64
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /config/node-red/node_modules/node-crc
gyp ERR! node -v v12.14.0
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok 
npm WARN multiple-select@1.5.2 requires a peer of jquery@1.9.1 - 3 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-crc@1.2.2 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the node-crc@1.2.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

Looks like some build-essentials is missing :(

posted by MTrab over 5 years ago

build-base would be the Alpine equivalent. To be fair I do not believe this is an issue with the addon itself at this stage.

posted by sinclairpaul over 5 years ago

Paul is right, this is not an add-on issue. You are trying to install a node that requires additional packages, you need to make sure you specify them or else it will, of course, fail to build.

posted by frenck over 5 years ago

@frenck how do I see what I need to install? I have never experienced this before, and as written, it works as supposed in a fresh Node-Red installation.

posted by MTrab over 5 years ago

Multiple options: Check the manual of the thing you want to install, ask for help @ the thing you want to install or read the error messages and satisfy the things it needs.

With millions of npm packages out there in the world, I'm not aware of the requirements of every single one of them.

posted by frenck over 5 years ago

I'm fully aware that you don't know the dependencies of every module - I just hoped you could point me to some file or whatever where you could see the dependencies.

As I read the error logs, I don't see much other than make that's missing. And I just find it odd that it works on a vanilla Node-Red docker and not this - perhaps too much have been removed from the add-on docker image.

posted by MTrab over 5 years ago

There is no reason to ship build utils with a docker image. It makes them unneeded large, especially considering we are dealing with Pi's a lot here.

That said, you can add the build utils if you need them, using the system packages options provided. Adding build-base is always a good starting point.

posted by frenck over 5 years ago

Did that. Now I'm stranded on failure to install serialports 6.2.2 (I know, old version)

Might just drop installing that palette, not much response from the developer of the module (originally opened an issue for this ~1 year ago, which have had next to none responses)

Thanks for your time.

posted by MTrab over 5 years ago

That serial ports version isn't compatible with Node 12, which powers this add-on.

posted by frenck over 5 years ago

This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread.

posted by addons-assistant[bot] about 5 years ago

Fund this Issue

$0.00
Funded

Pull requests