DeeeeLAN / homebridge-sleepiq

SleepIQ Homebridge plugin
18 stars 10 forks source link

Unhandled promise exceptions in console #13

Closed 400HPMustang closed 3 years ago

400HPMustang commented 5 years ago

Getting the following output in my console

(node:9720) UnhandledPromiseRejectionWarning: RequestError: Error: connect ETIMEDOUT 52.23.71.210:443 at new RequestError (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\node_modules\request-promise-core\lib\errors.js:14:15) at Request.plumbing.callback (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\node_modules\request-promise-core\lib\plumbing.js:87:29) at Request.RP$callback [as _callback] (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\node_modules\request-promise-core\lib\plumbing.js:46:31) at self.callback (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\node_modules\request\request.js:185:22) at Request.emit (events.js:198:13) at Request.onRequestError (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\node_modules\request\request.js:881:8) at ClientRequest.emit (events.js:198:13) at TLSSocket.socketErrorListener (_http_client.js:392:9) at TLSSocket.emit (events.js:198:13) at emitErrorNT (internal/streams/destroy.js:91:8) at emitErrorAndCloseNT (internal/streams/destroy.js:59:3) at process._tickCallback (internal/process/next_tick.js:63:19) (node:9720) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 24)

DeeeeLAN commented 5 years ago

If you still have the log, can you give me the output leading up to that error? This doesn't actually tell me where it occurred.

400HPMustang commented 5 years ago

I rolled the log because I installed or upgraded some plugins this morning and restarted homebridge. When/if it happens again, I'll attach the log.

400HPMustang commented 5 years ago

Here's the console output again and the relevant logs from your plugin attached. Nothing jumps out at me SleepNumberLog.txt

`(node:2320) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'forEach' of undefined at SleepNumberPlatform.parseData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:322:15) at SleepNumberPlatform.fetchData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:315:18) at process._tickCallback (internal/process/next_tick.js:68:7) (node:2320) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 5) (node:2320) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. (node:2320) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'forEach' of undefined at SleepNumberPlatform.parseData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:322:15) at SleepNumberPlatform.fetchData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:315:18) at process._tickCallback (internal/process/next_tick.js:68:7) (node:2320) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 9) (node:2320) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'forEach' of undefined at SleepNumberPlatform.parseData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:322:15) at SleepNumberPlatform.fetchData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:315:18) at process._tickCallback (internal/process/next_tick.js:68:7) (node:2320) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 12) SleepNumberLog.txt

(node:2320) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'forEach' of undefined at SleepNumberPlatform.parseData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:322:15) at SleepNumberPlatform.fetchData (C:\Users\Admin\AppData\Roaming\npm\node_modules\homebridge-sleepiq\index.js:315:18) at process._tickCallback (internal/process/next_tick.js:68:7) (node:2320) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 17)`

DeeeeLAN commented 5 years ago

Actually that is great, it gives me the line number in index.js so I know what is failing. Is it causing your system to stop responding (high priority) or is it just something you noticed in the logs (low priority)?

400HPMustang commented 5 years ago

Low priority. Something I noticed in the logs. My system is still responding. Thank you!

DeeeeLAN commented 3 years ago

Should all be fixed now.