dinmammas / homebridge-robonect

Homebridge plugin for Robonect-powered lawn mowers
ISC License
3 stars 3 forks source link

SyntaxError prevents homebridge from launch #3

Closed daniestermann closed 4 years ago

daniestermann commented 4 years ago

My homebridge instance fails to boot due to an exception in the homebridge-robonect module. Is this connected to the new 1.2 firmware?

Exception

Loaded plugin: homebridge-robonect@1.0.22
Registering accessory 'homebridge-robonect.HomebridgeRobonect'
...
Homebridge is running on port 51826.
...
SyntaxError: Unexpected end of JSON input
     at JSON.parse (<anonymous>)
     at Request._callback (/usr/local/lib/node_modules/homebridge-robonect/index.js:47:25)
     at Request.self.callback (/usr/local/lib/node_modules/homebridge-robonect/node_modules/request/request.js:185:22)
     at Request.emit (events.js:315:20)
     at Request.<anonymous> (/usr/local/lib/node_modules/homebridge-robonect/node_modules/request/request.js:1154:10)
     at Request.emit (events.js:315:20)
     at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/homebridge-robonect/node_modules/request/request.js:1076:12)
     at Object.onceWrapper (events.js:421:28)
     at IncomingMessage.emit (events.js:327:22)
     at endReadableNT (_stream_readable.js:1201:12)
Got SIGTERM, shutting down Homebridge...

homebridge-robonect configuration

        {
            "accessory": "HomebridgeRobonect",
            "name": "Rasenmäher",
            "mower": "Husqvarna",
            "model": "105",
            "robonect-card": "HX",
            "serial-number": "xxxxxxxxx",
            "getUrl": "http://admin:xxxxx@192.168.86.180"
        }

Versions

What else do you need to know?

daniestermann commented 4 years ago

After updating the robonect firmware to daily build V1.2_Fix 2020-08-20, this issue no longer happens. Or was it just the reboot of the mower?

dinmammas commented 4 years ago

It's related to a bug in the Robonect firmware, but also related to my lazy programming ;) I will strive to do better.