zautrix / hm-iobroker

ioBroker packaged as a CCU-Addon for RaspberryMatic and the HomeMatic CCU3.
MIT License
26 stars 9 forks source link

update to js-controller 3.1.6 -> 3.3.18 fails #15

Open smart-m opened 2 years ago

smart-m commented 2 years ago

Hallo i have: Pi3 with raspberrymatic hm-iobroker 3.1.06

the update js-controller to version 3.3.18 (current) fails with a lot of errors After several attempts according to the instructions, I always had to completely uninstall iobroker and reinstall it with 3.1.06. Also update from admin 4.1.10 to 5.1.25 fails, because the version of js-controller ist to old.

what can i do? will there come a new version of hm-iobroker?

mirko

netmic10 commented 2 years ago

Hello,

I have the same issue.

This is the output on the ssh console of Raspberrymatic (@ Raspberry Pi 2):

# npm install iobroker.js-controller

> iobroker.js-controller@3.3.18 preinstall /usr/local/addons/hm-iobroker/node_modules/iobroker.js-controller
> node lib/preinstallCheck.js

Could not check npm version: Error: Timeout
Assuming that correct version is installed.

> iobroker.js-controller@3.3.18 install /usr/local/addons/hm-iobroker/node_modules/iobroker.js-controller
> node iobroker.js setup first

/usr/local/addons/hm-iobroker/node_modules/iobroker.js-controller/lib/tools.js:39
const FORBIDDEN_CHARS = /[^._\-/ :!#$%&()+=@^{}|~\p{Ll}\p{Lu}\p{Nd}]+/gu;
                        ^

SyntaxError: Invalid regular expression: /[^._\-/ :!#$%&()+=@^{}|~\p{Ll}\p{Lu}\p{Nd}]+/: Invalid property name in character class
    at Object.<anonymous> (/usr/local/addons/hm-iobroker/node_modules/iobroker.js-controller/lib/tools.js:39:25)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/usr/local/addons/hm-iobroker/node_modules/iobroker.js-controller/lib/setup.js:20:31)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.3.2 (node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.3.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: osx-temperature-sensor@1.0.7 (node_modules/osx-temperature-sensor):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for osx-temperature-sensor@1.0.7: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! iobroker.js-controller@3.3.18 install: `node iobroker.js setup first`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the iobroker.js-controller@3.3.18 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!     /tmp/npm-cache/_logs/2021-11-03T17_15_24_210Z-debug.log

So, in detail the following command in the installation script fails: node iobroker.js setup first

Regards Michael

Apollon77 commented 2 years ago

WHich nodejs version? Wherethe nodejs is from? We saw that error once before on a freebsd system with a self-compiled nodejs and readon was that one unicode/regex lib was not compiled in ...

netmic10 commented 2 years ago

It is the version which is coming with the actual Raspberrymatic release.

node -v

v12.22.5

uname -mrspvio

Linux 5.10.60 #1 SMP PREEMPT Sat Oct 9 10:57:12 UTC 2021 armv7l unkn own unknown GNU/Linux

Apollon77 commented 2 years ago

Ok, then no idea whats "inside" that one ... maybe they need to deliver a correct compiled one

netmic10 commented 1 year ago

@smart-m, issue #9 is related to the same root cause and now fixed with this commit. So, with the next Raspberrymatic release, you can test the ioBroker add on upgrade (js-controller and admin) again.