ebaauw / homebridge-deconz

Homebridge plugin for deCONZ
Apache License 2.0
135 stars 7 forks source link

Configured Name: warning: set: RangeError: cannot be empty #159

Closed jan666 closed 11 months ago

jan666 commented 11 months ago

Hello,

I just did the first step to migrate from homebridge-hue to homebridge-deconz. I set up a second homebridge instance on a new Raspberry Pi for testing. Installed Homebridge, added homebridge-deconz as child bridge and added my gateway. Everything looks ok so far but I have mulitple errors in the log all the time:

[6.9.2023, 10:23:40] [deCONZ] Esszimmer #4: Configured Name: changed to "" (from "Esszimmer #4")
[6.9.2023, 10:23:40] [deCONZ] Esszimmer #4: Configured Name: warning: set: RangeError: cannot be empty
    at CharacteristicDelegate.setter [as _setter] (/var/lib/homebridge/node_modules/homebridge-deconz/node_modules/homebridge-lib/lib/ServiceDelegate/index.js:122:19)
    at CharacteristicDelegate._onSet (/var/lib/homebridge/node_modules/homebridge-deconz/node_modules/homebridge-lib/lib/CharacteristicDelegate.js:409:29)
    at ConfiguredName.emit (node:events:513:28)
    at /var/lib/homebridge/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2596:16
    at new Promise (<anonymous>)
    at ConfiguredName.<anonymous> (/var/lib/homebridge/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2594:14)
    at step (/var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:193:27)
    at Object.next (/var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:174:57)
    at /var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:167:75
    at new Promise (<anonymous>)
[6.9.2023, 10:23:40] [deCONZ] Deckenleuchte Badezimmer History: Configured Name: changed to "" (from "Deckenleuchte Badezimmer History")
[6.9.2023, 10:23:40] [deCONZ] Deckenleuchte Badezimmer History: Configured Name: warning: set: RangeError: cannot be empty
    at CharacteristicDelegate.setter [as _setter] (/var/lib/homebridge/node_modules/homebridge-deconz/node_modules/homebridge-lib/lib/ServiceDelegate/index.js:122:19)
    at CharacteristicDelegate._onSet (/var/lib/homebridge/node_modules/homebridge-deconz/node_modules/homebridge-lib/lib/CharacteristicDelegate.js:409:29)
    at ConfiguredName.emit (node:events:513:28)
    at /var/lib/homebridge/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2596:16
    at new Promise (<anonymous>)
    at ConfiguredName.<anonymous> (/var/lib/homebridge/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2594:14)
    at step (/var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:193:27)
    at Object.next (/var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:174:57)
    at /var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:167:75
    at new Promise (<anonymous>)
[6.9.2023, 10:23:39] [deCONZ] Pumpenschalter Badezimmer: Configured Name: changed to "" (from "Pumpenschalter Badezimmer")
[6.9.2023, 10:23:39] [deCONZ] Pumpenschalter Badezimmer: Configured Name: warning: set: RangeError: cannot be empty
    at CharacteristicDelegate.setter [as _setter] (/var/lib/homebridge/node_modules/homebridge-deconz/node_modules/homebridge-lib/lib/ServiceDelegate/index.js:122:19)
    at CharacteristicDelegate._onSet (/var/lib/homebridge/node_modules/homebridge-deconz/node_modules/homebridge-lib/lib/CharacteristicDelegate.js:409:29)
    at ConfiguredName.emit (node:events:513:28)
    at /var/lib/homebridge/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2596:16
    at new Promise (<anonymous>)
    at ConfiguredName.<anonymous> (/var/lib/homebridge/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2594:14)
    at step (/var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:193:27)
    at Object.next (/var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:174:57)
    at /var/lib/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:167:75
    at new Promise (<anonymous>)

This error shows up all the time for many devices. Is this a bug?

ebaauw commented 11 months ago

[6.9.2023, 10:23:40] [deCONZ] Esszimmer #4: Configured Name: changed to "" (from "Esszimmer #4")

The service name (tile name) is updated from HomeKit to an empty string, which Homebridge deCONZ doesn't accept by design. I don't think HomeKit should even allow this, but some HomeKit apps do, apparently. Could also be a side-effect of HomeKit syncing configuration changes between your Apple devices over iCloud. Or a HomeKit app that shows Configured Name as characteristic.

jan666 commented 11 months ago

It stopped after some time. So I guess it's not really a problem. Thanks!