I've hit an issue - I've updated from version 3.x to version 4.1.0 - Node red goes into a constant loop of rebooting on first deployment. This does not appear to be related to the another issue raised where messages were sent too soon before the Hue Bridge node is configured.
I have deleted all the hue magic nodes including the bridge. Node Red then loads without issue.
Just adding back the Hue Bridge node without any others - configuring it and hitting deploy - Node red goes into a loop of rebooting again.
If the Hue Bridge node is disabled then it deploys correctly. You can then enable the Hue bridge node and everything is fine until node red is restarted. Then it gets into the rebooting loop.
Hue Magic v4.1.0
Node-RED version: v2.1.3
NodeJS version: v16.13.0
Device running Node-RED: Raspberry Pi
Hue Bridge - 1.49.1949203030
On looking at the logs I see lots of this:-
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
TypeError: Cannot read properties of undefined (reading 'length')
at new HueBridgeMessage (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/utils/messages.js:17:61)
at HueBridge.get (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:306:23)
at /home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge.js:84:30
at EventEmitter. (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:556:7)
at EventEmitter.emit (node:events:390:28)
at EventEmitter.emit (node:domain:475:12)
at HueBridge.pushUpdatedState (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:275:16)
at Timeout._onTimeout (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:177:13)
at listOnTimeout (node:internal/timers:557:17)
at processTimers (node:internal/timers:500:7)
TypeError: Cannot read properties of undefined (reading 'length')
at new HueBridgeMessage (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/utils/messages.js:17:61)
at HueBridge.get (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:306:23)
at /home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge.js:84:30
at EventEmitter. (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:556:7)
at EventEmitter.emit (node:events:390:28)
at EventEmitter.emit (node:domain:475:12)
at HueBridge.pushUpdatedState (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:275:16)
at Timeout._onTimeout (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:177:13)
at listOnTimeout (node:internal/timers:557:17)
at processTimers (node:internal/timers:500:7)
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
TypeError: Cannot read properties of undefined (reading 'length')
at new HueBridgeMessage (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/utils/messages.js:17:61)
at HueBridge.get (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:306:23)
at /home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge.js:84:30
at EventEmitter. (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:556:7)
at EventEmitter.emit (node:events:390:28)
at EventEmitter.emit (node:domain:475:12)
at HueBridge.pushUpdatedState (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:275:16)
at Timeout._onTimeout (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:177:13)
at listOnTimeout (node:internal/timers:557:17)
at processTimers (node:internal/timers:500:7)
Hi Foddy,
Great work on this project!
I've hit an issue - I've updated from version 3.x to version 4.1.0 - Node red goes into a constant loop of rebooting on first deployment. This does not appear to be related to the another issue raised where messages were sent too soon before the Hue Bridge node is configured.
I have deleted all the hue magic nodes including the bridge. Node Red then loads without issue.
Just adding back the Hue Bridge node without any others - configuring it and hitting deploy - Node red goes into a loop of rebooting again.
If the Hue Bridge node is disabled then it deploys correctly. You can then enable the Hue bridge node and everything is fine until node red is restarted. Then it gets into the rebooting loop.
On looking at the logs I see lots of this:-
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason: TypeError: Cannot read properties of undefined (reading 'length') at new HueBridgeMessage (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/utils/messages.js:17:61) at HueBridge.get (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:306:23) at /home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge.js:84:30 at EventEmitter. (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:556:7)
at EventEmitter.emit (node:events:390:28)
at EventEmitter.emit (node:domain:475:12)
at HueBridge.pushUpdatedState (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:275:16)
at Timeout._onTimeout (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:177:13)
at listOnTimeout (node:internal/timers:557:17)
at processTimers (node:internal/timers:500:7)
TypeError: Cannot read properties of undefined (reading 'length')
at new HueBridgeMessage (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/utils/messages.js:17:61)
at HueBridge.get (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:306:23)
at /home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge.js:84:30
at EventEmitter. (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:556:7)
at EventEmitter.emit (node:events:390:28)
at EventEmitter.emit (node:domain:475:12)
at HueBridge.pushUpdatedState (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:275:16)
at Timeout._onTimeout (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:177:13)
at listOnTimeout (node:internal/timers:557:17)
at processTimers (node:internal/timers:500:7)
This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason:
TypeError: Cannot read properties of undefined (reading 'length')
at new HueBridgeMessage (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/utils/messages.js:17:61)
at HueBridge.get (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:306:23)
at /home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge.js:84:30
at EventEmitter. (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:556:7)
at EventEmitter.emit (node:events:390:28)
at EventEmitter.emit (node:domain:475:12)
at HueBridge.pushUpdatedState (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:275:16)
at Timeout._onTimeout (/home/pi/.node-red/node_modules/node-red-contrib-huemagic/huemagic/hue-bridge-config.js:177:13)
at listOnTimeout (node:internal/timers:557:17)
at processTimers (node:internal/timers:500:7)
Let me know of you need any more info
Thanks for your help, Jon