homebridge-eufy-security / plugin

Homebridge plugin to control certain Eufy Security devices
Apache License 2.0
173 stars 23 forks source link

[Bug]: Changing Eufy Base status crashes whole Homebridge #518

Open mariomaz87 opened 9 months ago

mariomaz87 commented 9 months ago

What happened?

Since yesterday, changing the Eufy base status from Homekit crashes my whole Homebridge instance. It was working fine before.

Device Type

Station (Supported)

Plugin Version

v2.0.x (Supported)

HomeBridge Version

v1.6.x (Supported)

NodeJS Version

v18 (Supported)

Operating System

Raspbian 10+ (Supported)

Relevant log output

[02/22/2024, 08:57:55]  [EufySecurity]  INFO    Eufy Base Request to change station guard mode to: DISARM(3)
[2/22/2024, 8:57:56 AM] InvalidPropertyValueError: Invalid value for this property according to metadata
    at validValue (/homebridge/node_modules/homebridge-eufy-security/node_modules/eufy-security-client/src/utils.ts:137:19)
    at Station.setGuardMode (/homebridge/node_modules/homebridge-eufy-security/node_modules/eufy-security-client/src/http/station.ts:692:19)
    at StationAccessory.handleSecuritySystemTargetStateSet (/homebridge/node_modules/homebridge-eufy-security/src/plugin/accessories/StationAccessory.ts:350:19)
    at setValue (/homebridge/node_modules/homebridge-eufy-security/src/plugin/accessories/StationAccessory.ts:99:33)
    at SecuritySystemTargetState.setHandler (/homebridge/node_modules/homebridge-eufy-security/src/plugin/accessories/BaseAccessory.ts:161:25)
    at SecuritySystemTargetState.<anonymous> (/homebridge/node_modules/homebridge/node_modules/hap-nodejs/src/lib/Characteristic.ts:2547:42)
    at step (/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:195:27)
    at Object.next (/homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:176:57)
    at /homebridge/node_modules/homebridge/node_modules/tslib/tslib.js:169:75
    at new Promise (<anonymous>)
[2/22/2024, 8:57:56 AM] Got SIGTERM, shutting down Homebridge...
[02/22/2024, 08:57:56]  [EufySecurity]  INFO    Finished shutdown!
[2/22/2024, 8:57:56 AM] Got SIGTERM, shutting down child bridge process...
[02/22/2024, 08:58:00]  [EufySecurity]  WARN    Eufy Base Changing guard mode to DISARM(3) did not complete. Retry...'
[2/22/2024, 8:58:00 AM] InvalidPropertyValueError: Invalid value for this property according to metadata
    at validValue (/homebridge/node_modules/homebridge-eufy-security/node_modules/eufy-security-client/src/utils.ts:137:19)
    at Station.setGuardMode (/homebridge/node_modules/homebridge-eufy-security/node_modules/eufy-security-client/src/http/station.ts:692:19)
    at Timeout._onTimeout (/homebridge/node_modules/homebridge-eufy-security/src/plugin/accessories/StationAccessory.ts:359:21)
    at listOnTimeout (node:internal/timers:569:17)
    at processTimers (node:internal/timers:512:7)
[2/22/2024, 8:58:01 AM] [HB Supervisor] Homebridge Process Ended. Code: 143, Signal: null
[2/22/2024, 8:58:06 AM] [HB Supervisor] Restarting Homebridge...

config

{
    "username": "email",
    "password": "password",
    "country": "IT",
    "deviceName": "",
    "stations": [
        {
            "serialNumber": "serialnumber",
            "manualTriggerModes": [
                1,
                2
            ],
            "hkNight": 3,
            "hkHome": 1,
            "hkAway": 0
        }
    ],
    "ignoreDevices": [
        "serialnumber",
        "serialnumber",
        "serialnumber",
        "serialnumber"
    ],
    "platform": "EufySecurity",
    "ignoreStations": [],
    "cleanCache": true
}
github-actions[bot] commented 9 months ago

Did you check this Common Issues pages ?

mariomaz87 commented 9 months ago

The crash happens only when changing to Off\Disarmed. I was using the "global settings" for this specific state. I changed it to Eufy Disarmed and now it works.