evgolsh / homebridge-crestron-home

Homebridge plugin for Crestron Home
Apache License 2.0
5 stars 2 forks source link

Incorrect Child Node warning of devices and eventual crash within Homekit. #7

Closed wolfiegrr closed 7 months ago

wolfiegrr commented 8 months ago

Describe The Bug: Too many devices are reported per Child Node even though it is well under 150 per node, eventually after ~2-4 weeks, the entire system becomes unresponsive, Bridge needs to be removed and re-added to homekit.

To Reproduce:

Expected behavior:

Logs: 12/8/2023, 6:50:56 AM] [Crestron Home Platform] Updating Devices state [12/8/2023, 6:50:57 AM] [Crestron Home Platform] Updating Devices state [12/8/2023, 6:50:57 AM] [Crestron Home Platform] Succsessfully authinticated, working with version: 2.000.0003 [12/8/2023, 6:50:57 AM] [Crestron Home Platform] Returning more than 149 devices, Homebridge may crash - 329 [12/8/2023, 6:50:57 AM] [Crestron Home Platform] Returning more than 149 devices, Homebridge may crash - 329 [12/8/2023, 6:51:16 AM] [Crestron Home Platform] Updating Devices state [12/8/2023, 6:51:17 AM] [Crestron Home Platform] Returning more than 149 devices, Homebridge may crash - 329

Show the Homebridge logs here, remove any sensitive information.



**Plugin Config:**

        {
            "name": "Crestron Home Platform",
            "crestronHost": "192.168.1.2",
            "token": "XXXXX,
            "enabledTypes": [
                "Switch"
            ],
            "updateInterval": 60,
            "platform": "CrestronHomePlatform",
            "_bridge": {
                "username": "XXXXX",
                "port": 42490
            }
        },
        {
            "name": "Crestron Home Platform",
            "crestronHost": "192.168.1.3",
            "token": "XXXXX",
            "enabledTypes": [
                "Shade"
            ],
            "updateInterval": 50,
            "platform": "CrestronHomePlatform",
            "_bridge": {
                "username": "XXXXX",
                "port": 51730
            }
        },
        {
            "name": "Crestron Home Platform",
            "crestronHost": "192.168.1.4",
            "token": "XXXXX",
            "enabledTypes": [
                "Dimmer"
            ],
            "updateInterval": 40,
            "platform": "CrestronHomePlatform",
            "_bridge": {
                "username": "XXXXX",
                "port": 49157
            }
        }
    ]

**Screenshots:**

**Environment:**
Raspberry Pi - latest

1.1.5 (just upgraded and will be testing on 1.1.6)
* **Homebridge Version**:  latest
* **Node.js Version**: v18.18.2
* **NPM Version**: <!-- npm -v -->
* **Operating System**:  RaspberryPI - Debian GNU/Linux Bullseye (11)

<!-- Click the "Preview" tab before you submit to ensure the formatting is correct. -->
evgolsh commented 8 months ago

You can safely ignore the warning. Please try using version 1.1.6, there is a fix addressing stability issues.

wolfiegrr commented 8 months ago

Just updated to 1.1.6 the same day of that post. I'll monitor it on the new version. Thank you!

evgolsh commented 8 months ago

Fix in 1.1.6 didn't help. The issue the same as mentioned in the issue #3 As a workaround, you don't need to remove the bridge, deleting cached accessories will help. In my case (running Homebridge on Raspbian):

Ssh to the Raspberry Pi cd /var/lib/homebridge/accessories/ sudo hb-service stop sudo rm cachedAccessories.[YOUR-BRIDGE] sudo hb-service start

The Homekit should work properly after this.

evgolsh commented 7 months ago

I believe @mcm246 fixed the issue in 1.1.8 along with incorrect warning Please try it.