EricAndrechek / homebridge-display

Homebridge-Display, a Homebridge plugin that allows you to control and view Spotify, see the weather forecast and current conditions, see news articles, control some Homebridge devices, and much, much more!
MIT License
126 stars 5 forks source link

Got SIGTERM #316

Open Jorick-tv opened 2 years ago

Jorick-tv commented 2 years ago

Getting errors in the Homebridge Log, restarting

Not sure what causes this, see attached log

[5/12/2022, 12:32:15 PM] TypeError: device.currentState is not a function
    at sono.get_status (/usr/lib/node_modules/homebridge-display/dist/sonos-controller.js:18:20)
    at Socket.<anonymous> (/usr/lib/node_modules/homebridge-display/dist/index.js:563:19)
    at Socket.emit (node:events:527:28)
    at /usr/lib/node_modules/homebridge-display/node_modules/socket.io/dist/socket.js:435:32
    at processTicksAndRejections (node:internal/process/task_queues:78:11)
[5/12/2022, 12:32:15 PM] Got SIGTERM, shutting down Homebridge...
[5/12/2022, 12:32:15 PM] Got SIGTERM, shutting down child bridge process...
[5/12/2022, 12:32:20 PM] [HB Supervisor] Homebridge Process Ended. Code: 143, Signal: null
[5/12/2022, 12:32:25 PM] [HB Supervisor] Restarting Homebridge...
[5/12/2022, 12:32:25 PM] [HB Supervisor] Starting Homebridge with extra flags: -I
[5/12/2022, 12:32:25 PM] [HB Supervisor] Started Homebridge v1.4.1 with PID: 5088

Homebridge 1.4.1 Node JS v16.15.0 Raspbian GNU/Linux Buster (10)

EDIT:

Removed Sonos from the layout, this remains:

[5/12/2022, 1:21:21 PM] TypeError: Cannot read properties of undefined (reading 'get_status')
    at Socket.<anonymous> (/usr/lib/node_modules/homebridge-display/dist/index.js:563:19)
    at Socket.emit (node:events:527:28)
    at /usr/lib/node_modules/homebridge-display/node_modules/socket.io/dist/socket.js:435:32
    at processTicksAndRejections (node:internal/process/task_queues:78:11)

Still fatal

EricAndrechek commented 2 years ago

Sorry for the late response, I have been busy with work. So the first half of the issue is hard for me to debug without a Sonos device, so for the upcoming v3 release, I will not be including Sonos. The second half is due to the client device caching the Sonos widget and still trying to use the Sonos backend. This was an oversight on my part and is already fixed in the v3 release. Thanks for pointing this out!