Error while installing node-red-contrib-modbus

Hi, it´s my first post here. I got the Node-RED version: v10.15.3 and the Node.js version: v0.20l.7. I tried to install the node-red-contrib-modbus node, but i got a bunch of erorrs after starting the installation in node-red. Can someone help me, what this error means?


Please copy/paste the log here, not screenshot. That is virtually illegible on my system. When pasting use the </> button at the top of the forum entry window.

You haven't got node-red version 10.15.3, that may be the nodejs version. However 0.201.7 is also not the node-red version so please clarify that.

Oh yeah sorry for that. I mixed the Versions up, so The Node-Red Version is: v0.20.7 and the Node.js version is: v10.15.3. And here again my error messages:

2021-09-29T08:37:55.447Z Install : node-red-contrib-modbus 5.14.1

2021-09-29T08:37:55.455Z npm.cmd install --no-audit --no-update-notifier --save --save-prefix="~" --production node-red-contrib-modbus@5.14.1
2021-09-29T08:37:58.803Z [err] npm
2021-09-29T08:37:58.803Z [err]  WARN registry Unexpected warning for https://wain05400.apa.gad.schneider-electric.com:4878/: Miscellaneous Warning UNABLE_TO_VERIFY_LEAF_SIGNATURE: request to https://wain05400.apa.gad.schneider-electric.com:4878/node-red-contrib-modbus failed, reason: unable to verify the first certificate
2021-09-29T08:37:58.803Z [err] npm
2021-09-29T08:37:58.803Z [err]  WARN registry Using stale package data from https://wain05400.apa.gad.schneider-electric.com:4878/ due to a request error during revalidation.
2021-09-29T08:38:11.431Z [out] 
2021-09-29T08:38:11.431Z [out] > @serialport/bindings@9.2.4 install C:\Users\labor\.node-red\node_modules\@serialport\bindings
2021-09-29T08:38:11.431Z [out] > prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild
2021-09-29T08:38:11.431Z [out] 
2021-09-29T08:38:34.133Z [err] prebuild-install
2021-09-29T08:38:34.133Z [err]  WARN install connect ECONNREFUSED 140.82.121.4:443
2021-09-29T08:38:34.150Z [out] 
2021-09-29T08:38:34.150Z [out] C:\Users\labor\.node-red\node_modules\@serialport\bindings>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) 
2021-09-29T08:38:34.150Z [out]  else (node "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild ) 
2021-09-29T08:38:34.517Z [err] gyp
2021-09-29T08:38:34.517Z [err]  ERR! 
2021-09-29T08:38:34.517Z [err] configure error 
2021-09-29T08:38:34.517Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! stack
2021-09-29T08:38:34.518Z [err]  Error: Command failed: C:\Python39\python.EXE -c import sys; print "%s.%s.%s" % sys.version_info[:3];
2021-09-29T08:38:34.518Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! stack
2021-09-29T08:38:34.518Z [err]    File "<string>", line 1
2021-09-29T08:38:34.518Z [err] gyp ERR!
2021-09-29T08:38:34.518Z [err]  stack     import sys; print "%s.%s.%s" % sys.version_info[:3];
2021-09-29T08:38:34.518Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! stack
2021-09-29T08:38:34.518Z [err]                        ^
2021-09-29T08:38:34.518Z [err] gyp ERR! 
2021-09-29T08:38:34.518Z [err] stack SyntaxError: invalid syntax
2021-09-29T08:38:34.518Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! stack
2021-09-29T08:38:34.518Z [err]  
2021-09-29T08:38:34.518Z [err] gyp ERR!
2021-09-29T08:38:34.518Z [err]  stack     at ChildProcess.exithandler (child_process.js:294:12)
2021-09-29T08:38:34.518Z [err] gyp ERR!
2021-09-29T08:38:34.518Z [err]  stack     at ChildProcess.emit (events.js:189:13)
2021-09-29T08:38:34.518Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! stack
2021-09-29T08:38:34.518Z [err]      at maybeClose (internal/child_process.js:970:16)
2021-09-29T08:38:34.518Z [err] gyp ERR! 
2021-09-29T08:38:34.518Z [err] stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
2021-09-29T08:38:34.518Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! System Windows_NT 10.0.19042
2021-09-29T08:38:34.518Z [err] gyp 
2021-09-29T08:38:34.518Z [err] ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
2021-09-29T08:38:34.518Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! cwd
2021-09-29T08:38:34.518Z [err]  C:\Users\labor\.node-red\node_modules\@serialport\bindings
2021-09-29T08:38:34.518Z [err] gyp 
2021-09-29T08:38:34.518Z [err] ERR! node -v v10.15.3
2021-09-29T08:38:34.518Z [err] gyp ERR! node-gyp -v
2021-09-29T08:38:34.518Z [err]  v3.8.0
2021-09-29T08:38:34.518Z [err] gyp
2021-09-29T08:38:34.518Z [err]  ERR! not ok
2021-09-29T08:38:34.518Z [err]  
2021-09-29T08:38:35.058Z [err] npm
2021-09-29T08:38:35.059Z [err]  ERR! code ELIFECYCLE
2021-09-29T08:38:35.059Z [err] npm
2021-09-29T08:38:35.059Z [err]  ERR! errno 1
2021-09-29T08:38:35.060Z [err] npm ERR! @serialport/bindings@9.2.4 install: `prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild`
2021-09-29T08:38:35.060Z [err] npm ERR!
2021-09-29T08:38:35.060Z [err]  Exit status 1
2021-09-29T08:38:35.060Z [err] npm 
2021-09-29T08:38:35.060Z [err] ERR! 
2021-09-29T08:38:35.060Z [err] npm 
2021-09-29T08:38:35.060Z [err] ERR! Failed at the @serialport/bindings@9.2.4 install script.
2021-09-29T08:38:35.060Z [err] npm 
2021-09-29T08:38:35.060Z [err] ERR! This is probably not a problem with npm. There is likely additional logging output above.
2021-09-29T08:38:35.084Z [err] 
2021-09-29T08:38:35.084Z [err] npm ERR! A complete log of this run can be found in:
2021-09-29T08:38:35.084Z [err] npm ERR!     C:\Users\labor\AppData\Roaming\npm-cache\_logs\2021-09-29T08_38_35_065Z-debug.log
2021-09-29T08:38:35.103Z rc=1

I have no idea why it is trying to fetch data from there. That domain name does not even exist. Have you got that setup as an npm repository?

Yes it is a repository of my company.

So you need to fix that first. npm can't access it. Neither can I (but perhaps it is not public).

Well...okay thanks anyway for the quick answers

This error is because you are using python3 but it looks like the serial module requires python2.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.