joeyhage / homebridge-alexa-smarthome

Connect Alexa devices to HomeKit
MIT License
81 stars 20 forks source link

Keeps restarting #143

Closed fredqm closed 2 months ago

fredqm commented 3 months ago

Thows an error and restarts after it successfully authenticates to Amazon

Just start the plugin

Pulls my devices

Logs:

[7/3/2024, 3:48:32 AM] [HomebridgeAlexaSmartHome] Successfully authenticated Alexa account.
[7/3/2024, 3:48:32 AM] TypeError: Cannot read properties of null (reading 'primary')
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/dist/domain/alexa/get-devices.js:43:45
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/node_modules/fp-ts/lib/Array.js:1267:85
    at Array.map (<anonymous>)
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/node_modules/fp-ts/lib/Array.js:1267:59
    at pipe (/var/lib/homebridge/node_modules/homebridge-alexa-smarthome/node_modules/fp-ts/lib/function.js:299:20)
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/dist/domain/alexa/get-devices.js:35:32
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/node_modules/fp-ts/lib/Option.js:646:53
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/node_modules/fp-ts/lib/function.js:209:24
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/node_modules/fp-ts/lib/internal.js:119:67
    at /var/lib/homebridge/node_modules/homebridge-alexa-smarthome/node_modules/fp-ts/lib/EitherT.js:83:97
[7/3/2024, 3:48:32 AM] Got SIGTERM, shutting down Homebridge...
[7/3/2024, 3:48:37 AM] [HB Supervisor] Homebridge Process Ended. Code: 143, Signal: null

Plugin Config:


{
    "devices": [
        "Bathroom Light"
    ],
    "excludeDevices": [],
    "auth": {
        "refreshInterval": 4,
        "proxy": {
            "clientHost": "192.168.31.177",
            "port": 9000
        }
    },
    "amazonDomain": "amazon.com",
    "language": "en-US",
    "performance": {
        "cacheTTL": 80,
        "backgroundRefresh": true
    },
    "debug": true,
    "platform": "HomebridgeAlexaSmartHome"
}

Screenshots:

Environment:

joeyhage commented 2 months ago

This is related to #138. You are using an alpha version of the plugin which is unstable. I plan to have a new alpha version published in a few hours to fix that.