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 when installing, docker on synology nas #99

Open
phralh opened this issue Jul 18, 2020 · 9 comments
Open

Error when installing, docker on synology nas #99

phralh opened this issue Jul 18, 2020 · 9 comments

Comments

@phralh
Copy link

phralh commented Jul 18, 2020

Hi,

I get these errors when trying to install in node-red official docker container on synology nas 718+. I have successfully installed on another synology nas and have tried both the latest node-red, and the previous successful version 10.3.

Any ideas?

2020-07-18T08:30:52.111Z Install : node-red-contrib-rfxcom 2.11.0

2020-07-18T08:30:52.146Z npm install --no-audit --no-update-notifier --save --save-prefix="~" --production [email protected]
2020-07-18T08:31:00.464Z [out]
2020-07-18T08:31:00.464Z [out] > @serialport/[email protected] install /data/node_modules/@serialport/bindings
2020-07-18T08:31:00.464Z [out] > prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild
2020-07-18T08:31:00.464Z [out]
2020-07-18T08:31:01.387Z [err] prebuild-install
2020-07-18T08:31:01.388Z [err] WARN install No prebuilt binaries found (target=10.17.0 runtime=node arch=x64 libc=musl platform=linux)
2020-07-18T08:31:02.438Z [out] make: Entering directory '/data/node_modules/@serialport/bindings/build'
2020-07-18T08:31:02.439Z [out] CXX(target) Release/obj.target/bindings/src/serialport.o
2020-07-18T08:31:03.807Z [err] In file included from ../src/./serialport.h:6,
2020-07-18T08:31:03.807Z [err] from ../src/serialport.cpp:1:
2020-07-18T08:31:03.807Z [err] ../../../nan/nan.h: In function 'void Nan::AsyncQueueWorker(Nan::AsyncWorker*)':
2020-07-18T08:31:03.807Z [err] ../../../nan/nan.h:2294:62: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.807Z [err] , reinterpret_cast<uv_after_work_cb>(AsyncExecuteComplete)
2020-07-18T08:31:03.807Z [err] ^
2020-07-18T08:31:03.872Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Open(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.872Z [err] ../src/serialport.cpp:78:69: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.872Z [err] uv_queue_work(uv_default_loop(), req, EIO_Open, (uv_after_work_cb)EIO_AfterOpen);
2020-07-18T08:31:03.872Z [err] ^~~~~~~~~~~~~
2020-07-18T08:31:03.878Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Update(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.878Z [err] ../src/serialport.cpp:135:71: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.878Z [err] uv_queue_work(uv_default_loop(), req, EIO_Update, (uv_after_work_cb)EIO_AfterUpdate);
2020-07-18T08:31:03.878Z [err] ^~~~~~~~~~~~~~~
2020-07-18T08:31:03.881Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Close(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.881Z [err] ../src/serialport.cpp:175:70: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.881Z [err] uv_queue_work(uv_default_loop(), req, EIO_Close, (uv_after_work_cb)EIO_AfterClose);
2020-07-18T08:31:03.881Z [err] ^~~~~~~~~~~~~~
2020-07-18T08:31:03.884Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Flush(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.884Z [err] ../src/serialport.cpp:215:70: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.884Z [err] uv_queue_work(uv_default_loop(), req, EIO_Flush, (uv_after_work_cb)EIO_AfterFlush);
2020-07-18T08:31:03.884Z [err] ^~~~~~~~~~~~~~
2020-07-18T08:31:03.888Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Set(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.888Z [err] ../src/serialport.cpp:270:68: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.888Z [err] uv_queue_work(uv_default_loop(), req, EIO_Set, (uv_after_work_cb)EIO_AfterSet);
2020-07-18T08:31:03.888Z [err] ^~~~~~~~~~~~
2020-07-18T08:31:03.891Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Get(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.891Z [err] ../src/serialport.cpp:314:68: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.891Z [err] uv_queue_work(uv_default_loop(), req, EIO_Get, (uv_after_work_cb)EIO_AfterGet);
2020-07-18T08:31:03.891Z [err] ^~~~~~~~~~~~
2020-07-18T08:31:03.898Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE GetBaudRate(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.898Z [err] ../src/serialport.cpp:363:76: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.898Z [err] uv_queue_work(uv_default_loop(), req, EIO_GetBaudRate, (uv_after_work_cb)EIO_AfterGetBaudRate);
2020-07-18T08:31:03.898Z [err] ^~~~~~~~~~~~~~~~~~~~
2020-07-18T08:31:03.903Z [err] ../src/serialport.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE Drain(Nan::NAN_METHOD_ARGS_TYPE)':
2020-07-18T08:31:03.903Z [err] ../src/serialport.cpp:409:70: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:03.903Z [err] uv_queue_work(uv_default_loop(), req, EIO_Drain, (uv_after_work_cb)EIO_AfterDrain);
2020-07-18T08:31:03.903Z [err] ^~~~~~~~~~~~~~
2020-07-18T08:31:03.908Z [err] ../src/serialport.cpp: At global scope:
2020-07-18T08:31:03.908Z [err] ../src/serialport.cpp:430:28: warning: unnecessary parentheses in declaration of 'ToParityEnum' [-Wparentheses]
2020-07-18T08:31:03.908Z [err] SerialPortParity NAN_INLINE(ToParityEnum(const v8::Localv8::String& v8str)) {
2020-07-18T08:31:03.908Z [err] ^
2020-07-18T08:31:03.909Z [err] ../src/serialport.cpp:449:30: warning: unnecessary parentheses in declaration of 'ToStopBitEnum' [-Wparentheses]
2020-07-18T08:31:03.909Z [err] SerialPortStopBits NAN_INLINE(ToStopBitEnum(double stopBits)) {
2020-07-18T08:31:03.909Z [err] ^
2020-07-18T08:31:03.911Z [err] In file included from ../../../nan/nan.h:56,
2020-07-18T08:31:03.911Z [err] from ../src/./serialport.h:6,
2020-07-18T08:31:03.911Z [err] from ../src/serialport.cpp:1:
2020-07-18T08:31:03.911Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node.h:573:43: warning: cast between incompatible function types from 'void ()(Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE)' {aka 'void ()(v8::Localv8::Object)'} to 'node::addon_register_func' {aka 'void ()(v8::Localv8::Object, v8::Localv8::Value, void)'} [-Wcast-function-type]
2020-07-18T08:31:03.911Z [err] (node::addon_register_func) (regfunc),
2020-07-18T08:31:03.911Z [err] ^
2020-07-18T08:31:03.911Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node.h:607:3: note: in expansion of macro 'NODE_MODULE_X'
2020-07-18T08:31:03.911Z [err] NODE_MODULE_X(modname, regfunc, NULL, 0) // NOLINT (readability/null_usage)
2020-07-18T08:31:03.911Z [err] ^~~~~~~~~~~~~
2020-07-18T08:31:03.911Z [err] ../src/serialport.cpp:483:1: note: in expansion of macro 'NODE_MODULE'
2020-07-18T08:31:03.911Z [err] NODE_MODULE(serialport, init);
2020-07-18T08:31:03.911Z [err] ^~~~~~~~~~~
2020-07-18T08:31:03.975Z [err] In file included from /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node.h:63,
2020-07-18T08:31:03.975Z [err] from ../../../nan/nan.h:56,
2020-07-18T08:31:03.975Z [err] from ../src/./serialport.h:6,
2020-07-18T08:31:03.975Z [err] from ../src/serialport.cpp:1:
2020-07-18T08:31:03.975Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h: In instantiation of 'void v8::PersistentBase::SetWeak(P*, typename v8::WeakCallbackInfo

::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo

::Callback = void ()(const v8::WeakCallbackInfonode::ObjectWrap&)]':
2020-07-18T08:31:03.975Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node_object_wrap.h:84:78: required from here
2020-07-18T08:31:03.975Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h:9502:16: warning: cast between incompatible function types from 'v8::WeakCallbackInfonode::ObjectWrap::Callback' {aka 'void (
)(const v8::WeakCallbackInfonode::ObjectWrap&)'} to 'Callback' {aka 'void ()(const v8::WeakCallbackInfo&)'} [-Wcast-function-type]
2020-07-18T08:31:03.975Z [err] reinterpret_cast(callback), type);
2020-07-18T08:31:03.975Z [err] ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2020-07-18T08:31:03.998Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h: In instantiation of 'void v8::PersistentBase::SetWeak(P
, typename v8::WeakCallbackInfo

::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo

::Callback = void ()(const v8::WeakCallbackInfoNan::ObjectWrap&)]':
2020-07-18T08:31:03.998Z [err] ../../../nan/nan_object_wrap.h:65:61: required from here
2020-07-18T08:31:03.998Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h:9502:16: warning: cast between incompatible function types from 'v8::WeakCallbackInfoNan::ObjectWrap::Callback' {aka 'void (
)(const v8::WeakCallbackInfoNan::ObjectWrap&)'} to 'Callback' {aka 'void ()(const v8::WeakCallbackInfo&)'} [-Wcast-function-type]
2020-07-18T08:31:05.689Z [out] CXX(target) Release/obj.target/bindings/src/serialport_unix.o
2020-07-18T08:31:07.060Z [err] In file included from ../src/serialport.h:6,
2020-07-18T08:31:07.060Z [err] from ../src/serialport_unix.cpp:2:
2020-07-18T08:31:07.060Z [err] ../../../nan/nan.h: In function 'void Nan::AsyncQueueWorker(Nan::AsyncWorker
)':
2020-07-18T08:31:07.060Z [err] ../../../nan/nan.h:2294:62: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:07.060Z [err] , reinterpret_cast<uv_after_work_cb>(AsyncExecuteComplete)
2020-07-18T08:31:07.060Z [err] ^
2020-07-18T08:31:07.196Z [err] In file included from /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node.h:63,
2020-07-18T08:31:07.196Z [err] from ../../../nan/nan.h:56,
2020-07-18T08:31:07.196Z [err] from ../src/serialport.h:6,
2020-07-18T08:31:07.196Z [err] from ../src/serialport_unix.cpp:2:
2020-07-18T08:31:07.196Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h: In instantiation of 'void v8::PersistentBase::SetWeak(P*, typename v8::WeakCallbackInfo

::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo

::Callback = void ()(const v8::WeakCallbackInfonode::ObjectWrap&)]':
2020-07-18T08:31:07.196Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node_object_wrap.h:84:78: required from here
2020-07-18T08:31:07.196Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h:9502:16: warning: cast between incompatible function types from 'v8::WeakCallbackInfonode::ObjectWrap::Callback' {aka 'void (
)(const v8::WeakCallbackInfonode::ObjectWrap&)'} to 'Callback' {aka 'void ()(const v8::WeakCallbackInfo&)'} [-Wcast-function-type]
2020-07-18T08:31:07.196Z [err] reinterpret_cast(callback), type);
2020-07-18T08:31:07.196Z [err] ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2020-07-18T08:31:07.219Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h: In instantiation of 'void v8::PersistentBase::SetWeak(P
, typename v8::WeakCallbackInfo

::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo

::Callback = void ()(const v8::WeakCallbackInfoNan::ObjectWrap&)]':
2020-07-18T08:31:07.219Z [err] ../../../nan/nan_object_wrap.h:65:61: required from here
2020-07-18T08:31:07.219Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h:9502:16: warning: cast between incompatible function types from 'v8::WeakCallbackInfoNan::ObjectWrap::Callback' {aka 'void (
)(const v8::WeakCallbackInfoNan::ObjectWrap&)'} to 'Callback' {aka 'void ()(const v8::WeakCallbackInfo&)'} [-Wcast-function-type]
2020-07-18T08:31:07.537Z [out] CXX(target) Release/obj.target/bindings/src/poller.o
2020-07-18T08:31:08.900Z [err] In file included from ../src/poller.cpp:1:
2020-07-18T08:31:08.900Z [err] ../../../nan/nan.h: In function 'void Nan::AsyncQueueWorker(Nan::AsyncWorker
)':
2020-07-18T08:31:08.900Z [err] ../../../nan/nan.h:2294:62: warning: cast between incompatible function types from 'void ()(uv_work_t)' {aka 'void ()(uv_work_s)'} to 'uv_after_work_cb' {aka 'void ()(uv_work_s, int)'} [-Wcast-function-type]
2020-07-18T08:31:08.900Z [err] , reinterpret_cast<uv_after_work_cb>(AsyncExecuteComplete)
2020-07-18T08:31:08.900Z [err] ^
2020-07-18T08:31:09.028Z [err] In file included from /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node.h:63,
2020-07-18T08:31:09.028Z [err] from ../../../nan/nan.h:56,
2020-07-18T08:31:09.028Z [err] from ../src/poller.cpp:1:
2020-07-18T08:31:09.028Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h: In instantiation of 'void v8::PersistentBase::SetWeak(P*, typename v8::WeakCallbackInfo

::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo

::Callback = void ()(const v8::WeakCallbackInfonode::ObjectWrap&)]':
2020-07-18T08:31:09.028Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/node_object_wrap.h:84:78: required from here
2020-07-18T08:31:09.028Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h:9502:16: warning: cast between incompatible function types from 'v8::WeakCallbackInfonode::ObjectWrap::Callback' {aka 'void (
)(const v8::WeakCallbackInfonode::ObjectWrap&)'} to 'Callback' {aka 'void ()(const v8::WeakCallbackInfo&)'} [-Wcast-function-type]
2020-07-18T08:31:09.028Z [err] reinterpret_cast(callback), type);
2020-07-18T08:31:09.028Z [err] ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2020-07-18T08:31:09.050Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h: In instantiation of 'void v8::PersistentBase::SetWeak(P
, typename v8::WeakCallbackInfo

::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo

::Callback = void ()(const v8::WeakCallbackInfoNan::ObjectWrap&)]':
2020-07-18T08:31:09.050Z [err] ../../../nan/nan_object_wrap.h:65:61: required from here
2020-07-18T08:31:09.050Z [err] /usr/src/node-red/.cache/node-gyp/10.17.0/include/node/v8.h:9502:16: warning: cast between incompatible function types from 'v8::WeakCallbackInfoNan::ObjectWrap::Callback' {aka 'void (
)(const v8::WeakCallbackInfoNan::ObjectWrap&)'} to 'Callback' {aka 'void (*)(const v8::WeakCallbackInfo&)'} [-Wcast-function-type]
2020-07-18T08:31:09.774Z [out] CXX(target) Release/obj.target/bindings/src/serialport_linux.o
2020-07-18T08:31:09.850Z [out] SOLINK_MODULE(target) Release/obj.target/bindings.node
2020-07-18T08:31:09.904Z [out] COPY Release/bindings.node
2020-07-18T08:31:09.910Z [out] make: Leaving directory '/data/node_modules/@serialport/bindings/build'
2020-07-18T08:31:09.942Z [out]
2020-07-18T08:31:09.942Z [out] > [email protected] postinstall /data/node_modules/serialport
2020-07-18T08:31:09.942Z [out] > node thank-you.js
2020-07-18T08:31:09.942Z [out]
2020-07-18T08:31:10.083Z [out] �[96m�[1mThank you for using serialport!�[96m�[1m
2020-07-18T08:31:10.083Z [out] �[0m�[96mIf you rely on this package, please consider supporting our open collective:�[22m�[39m
2020-07-18T08:31:10.083Z [out] > �[94mhttps://opencollective.com/serialport/donate�[0m
2020-07-18T08:31:10.083Z [out]
2020-07-18T08:31:10.083Z [out]
2020-07-18T08:31:10.452Z [out] + [email protected]
2020-07-18T08:31:10.452Z [out] added 86 packages from 49 contributors in 17.261s
2020-07-18T08:31:10.488Z rc=0

@maxwellhadley
Copy link
Owner

This appears to be a problem with the Serialport package version 9.0.0. It looks like it is using a version of nan.h that is not compatible with Node v 10.17.0 - please raise an issue at https://github.com/serialport/node-serialport/issues. Serialport is used by rfxcom, which node-red-contrib-rfxcom uses

@jag100UK
Copy link

I am getting the same issue when using Node-Red in Home Assistant.
I've also tried reverting back to previous snapshots but get similar errors.

Is there a way of reverting back to an older version of the previous node-red-contrib-rfxcom npm?

All of my flows in Node Red have been disabled.

Here is a copy of my log

18 Jul 22:03:38 - [info]

Welcome to Node-RED

18 Jul 22:03:38 - [info] Node-RED version: v1.1.0
18 Jul 22:03:38 - [info] Node.js version: v12.17.0
18 Jul 22:03:38 - [info] Linux 5.4.0-40-generic x64 LE
18 Jul 22:03:38 - [info] Loading palette nodes
18 Jul 22:03:39 - [info] Dashboard version 2.22.1 started at /endpoint/ui
/bin/sh: /opt/node_modules/node-red-node-pi-gpio/testgpio.py: not found
18 Jul 22:03:39 - [warn] rpi-gpio : Raspberry Pi specific node set inactive
18 Jul 22:03:39 - [warn] ------------------------------------------------------
18 Jul 22:03:39 - [warn] [node-red-contrib-rfxcom/rfxcom] Error: Cannot find module '@serialport/bindings'
Require stack:

  • /opt/node_modules/serialport/lib/index.js
  • /opt/node_modules/rfxcom/lib/rfxcom.js
  • /opt/node_modules/rfxcom/lib/index.js
  • /opt/node_modules/rfxcom/index.js
  • /opt/node_modules/node-red-contrib-rfxcom/rfxcom.js
  • /opt/node_modules/@node-red/registry/lib/loader.js
  • /opt/node_modules/@node-red/registry/lib/index.js
  • /opt/node_modules/@node-red/runtime/lib/nodes/index.js
  • /opt/node_modules/@node-red/runtime/lib/index.js
  • /opt/node_modules/node-red/lib/red.js
  • /opt/node_modules/node-red/red.js
    18 Jul 22:03:39 - [warn] ------------------------------------------------------
    18 Jul 22:03:39 - [info] Settings file : /etc/node-red/config.js
    18 Jul 22:03:39 - [info] Context store : 'default' [module=memory]
    18 Jul 22:03:39 - [info] User directory : /config/node-red/
    18 Jul 22:03:39 - [warn] Projects disabled : editorTheme.projects.enabled=false
    18 Jul 22:03:39 - [info] Flows file : /config/node-red/flows.json
    18 Jul 22:03:39 - [info] Server now running at http://127.0.0.1:46836/
    18 Jul 22:03:39 - [info] Waiting for missing types to be registered:
    18 Jul 22:03:39 - [info] - rfxtrx-port
    18 Jul 22:03:39 - [info] - rfx-detector-in
    18 Jul 22:03:39 - [info] - rfx-doorbell-in
    18 Jul 22:03:39 - [info] - rfx-sensor
    18 Jul 22:03:39 - [info] - rfx-lights-in
    18 Jul 22:03:39 - [info] - rfx-blinds-in
    18 Jul 22:03:39 - [info] - rfx-meter
    [22:03:39] INFO: Starting NGinx...
    nginx: [alert] detected a LuaJIT version which is not OpenResty's; many optimizations will be disabled and performance will be compromised (see https://github.com/openresty/luajit2 for OpenResty's LuaJIT or, even better, consider using the OpenResty releases from https://openresty.org/en/download.html)

@maxwellhadley
Copy link
Owner

You can revert back to an older version of a package by adding a version specifier to the npm install command:

npm install [email protected]

However, this will not fix everything, as the problem is two levels of dependency down:

node-red-contrib-rfxcom --> rfxcom --> serialport

I think you will need to manually roll back node-red-contrib-rfxcom to 2.10.0, then rfxcom to 2.2.0, then serialport to 8.0.8. In each case this has to be done from within the appropriate node_modules directory.

However, as this is a serialport problem, if you don't raise an issue with them it is unlikely to get fixed. I can't help you, but the serialport maintainers should be able to.

@jag100UK
Copy link

Thank you for your reply.

Forgive me for my lack of understanding, I'm not a developer and I don't understand what broke or how. I didn't knowingly make any changes before this happened.

What technically do we tell the "Serialport" maintainers?

In your previous message you mention its something incompatible with Node v 10.17.0. I dont know where this is configured, can I revert back to an older version? What settings are you running for it to work?

I've tried putting the followin line in my Node-Red configuration and as you suggested, it doesnt work
npm_packages:

I'm not seeing any other posts about this component being broken, which suggests it may be something on my installation.

I appreciate this isn't a Home Assistant forum, but is there anything in my configuration below that jumps out as a possible cause for this suddenly happening?

arch | x86_64
chassis | desktop
dev | false
docker | true
docker_version | 19.03.8
hassio | true
host_os | Ubuntu 20.04 LTS
installation_type | Home Assistant Supervised
os_name | Linux
os_version | 5.4.0-40-generic
python_version | 3.7.7
supervisor | 229
timezone | Europe/London
version | 0.112.4
virtualenv | false

This is my Node-Red configuration as defined in Home Assistant
credential_secret: ######
dark_mode: false
http_node:
username: ####
password: ####
http_static:
username: ''
password: ''
ssl: true
certfile: fullchain.pem
keyfile: privkey.pem
require_ssl: true
system_packages: []
npm_packages:

  • node-red-contrib-rfxcom
    init_commands: []

Many thanks

@phralh
Copy link
Author

phralh commented Jul 19, 2020

Hi,

Thanks for the replies. This solved my issue:

Manual installation of serialport@latest worked fine. Moved on to manual installation of node-rfxcom@latest which gave me the error above. Tested a few different versions of node-rfxcom and version 2.1.0 installed without error. Finally moved on to trying a few different versions of node-red-contrib-rfxcom and found that 2.1.1 worked fine on the latest docker image of node-red, version 1.1.2.

Regards
Fredrik

@maxwellhadley
Copy link
Owner

@phralh - I'm not sure I follow you there: do you say node-rfxcom version 2.1.0 with serialport latest (9.0.0) installs OK, but subsequent versions 2.1.1, 2.2.0, and 2.3.0 give the compiler error in your original report? That seems strange. However, I would expect any recent version of node-red-contrib-rfxcom to work OK, give or take a couple of bugs, with that combination. But node-red-contrib-rfxcom version 2.1.1 is very old indeed! Do you mean 2.11.1?

P.S. I'm still on Node-RED 1.0.3 and Node 12.14.0 here - I wonder if that makes a difference?

@jag100UK - I know people have had trouble with Home Assistant installs in the past that they have somehow fixed, though I don't use it myself. In your case it looks as if serialport has not been properly installed for some reason. You might try uninstalling node-red-contrib-rfxcom completely and then re-installing.

The common thread here appears to be the use of Docker: I have never tried using it here myself, might have to set up a test system...

@jag100UK
Copy link

jag100UK commented Jul 24, 2020

For anyone who has this issue using NodeRed on Home Assistant, a fix can be found here

serialport/node-serialport#2111

@maxwellhadley
Copy link
Owner

To force a complete reinstallation of serialport, including recompiling C++ sources where necessary, when you get an 'incompatible Node versions' message or for any other reason, the most reliable approach seems to be:

cd ~/.node-red
npm uninstall node-red-contrib-rfxcom node-red-node-serialport rfxcom serialport
npm install node-red-contrib-rfxcom node-red-node-serialport

It's best to uninstall all four packages, as it looks like some versions of npm don't follow the dependency chain all the way.

@maxwellhadley
Copy link
Owner

Version 2.13.0 now published to npm uses serialport 11.x.x, to retain compatibility with NodeJS v14.

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