SleepyBed IQ - Free SleepNumber Bed Monitor Plugin

Posted on
Thu Jul 12, 2018 3:05 pm
tatrog offline
Posts: 26
Joined: Nov 16, 2013

Re: SleepyBed IQ - Free SleepNumber Bed Monitor Plugin

Hi-just installed plugin. All actions and triggers are working but my log keeps filling up with the below. Any ideas? Love the plugin btw.
On vs 1.1.0


SleepyBed IQ Error Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
File "plugin.py", line 160, in runConcurrentThread
File "plugin.py", line 464, in parseBedData
AttributeError: 'NoneType' object has no attribute 'data'

SleepyBed IQ Error plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)
SleepyBed IQ Error Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
File "plugin.py", line 160, in runConcurrentThread
File "plugin.py", line 464, in parseBedData
AttributeError: 'NoneType' object has no attribute 'data'

SleepyBed IQ Error plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)
SleepyBed IQ Error Error in plugin execution runConcurrentThread:

Posted on
Thu Jul 12, 2018 8:49 pm
nsheldon offline
Posts: 1906
Joined: Aug 09, 2010
Location: CA

Re: SleepyBed IQ - Free SleepNumber Bed Monitor Plugin

Interesting. I need debug log output to track that down. Enable debug logging (Plugins -> SleepyBed IQ-> Toggle Debuggjng). Then reload the plugin and paste in the log into your response from where the plugin reloads to the error.

Posted on
Mon Jul 16, 2018 2:19 pm
tatrog offline
Posts: 26
Joined: Nov 16, 2013

Re: SleepyBed IQ - Free SleepNumber Bed Monitor Plugin

Turned on debugging and restarted the plugin but it didn't show any additional information. I did notice that the actions work fine (change tilt, sleep # etc) however the custom states are not updated at all eg. anyoneinbed=false always.


log after reloading with debugging on:

Reloading plugin "SleepyBed IQ 1.1.0"
Stopping plugin "SleepyBed IQ 1.1.0" (pid 34075)
Stopped plugin "SleepyBed IQ 1.1.0"
Starting plugin "SleepyBed IQ 1.1.0" (pid 34119)
Started plugin "SleepyBed IQ 1.1.0"
SleepyBed IQ Error Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
File "plugin.py", line 160, in runConcurrentThread
File "plugin.py", line 464, in parseBedData
AttributeError: 'NoneType' object has no attribute 'data'

SleepyBed IQ Error plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)
SleepyBed IQ Error Error in plugin execution runConcurrentThread:

Posted on
Mon Jul 16, 2018 3:37 pm
nsheldon offline
Posts: 1906
Joined: Aug 09, 2010
Location: CA

Re: SleepyBed IQ - Free SleepNumber Bed Monitor Plugin

Doesn't look like debugging was turned on. It should look something like this when debugging is on...

Code: Select all
   SleepyBed IQ                    Turning on debug logging
   SleepyBed IQ Debug              Stopping device: Bedroom Bed
   SleepyBed IQ Debug              Starting device: Bedroom Bed
   Reloading plugin "SleepyBed IQ 1.1.0"
   Stopping plugin "SleepyBed IQ 1.1.0" (pid 96413)
   SleepyBed IQ Debug              Stopping device: Bedroom Bed
   SleepyBed IQ Debug              shutdown called
   Stopped plugin "SleepyBed IQ 1.1.0"
   Starting plugin "SleepyBed IQ 1.1.0" (pid 96422)
   SleepyBed IQ Debug              Initializing Plugin.
   Started plugin "SleepyBed IQ 1.1.0"
   SleepyBed IQ Debug              startup called
   SleepyBed IQ Debug              Running plugin version check (if enabled).
   SleepyBed IQ Debug              Starting device: Bedroom Bed
   SleepyBed IQ Debug              Starting runConcurrentThread.
   SleepyBed IQ Debug              parseBedData called.
   SleepyBed IQ Debug              parseBedData: Setting device "Bedroom Bed" properties to:
com.nathansheldon.indigoplugin.sleepybed-iq : (dict)
     AllowOnStateChange : false (bool)
     AllowSensorValueChange : false (bool)
     SupportsBatteryLevel : false (bool)
     SupportsOnState : true (bool)
     SupportsSensorValue : false (bool)
     SupportsStatusRequest : true (bool)
     accountId : <redacted> (string)
     address : <redacted> (string)
     base : FlexFit 1 (string)
     bedId : <redacted> (string)
     bedName : Sheldon Bed (string)
     dualSleep : true (bool)
     generation : legacy (string)
     isKidsBed : false (bool)
     macAddress : <redacted> (string)
     model : C2 (string)
     purchaseDate : 2015-02-17T21:24:56Z (string)
     reference : <redacted> (string)
     registrationDate : 2015-03-04T19:39:57Z (string)
     returnRequestStatus : 0 (integer)
     serial :  (string)
     size : None (empty)
     sku : <redacted> (string)
     status : 1 (integer)
     timeZone : US/Pacific (string)
     version :  (string)
     zipCode : <redacted> (string)
   SleepyBed IQ Debug              parseBedData: Setting device "Bedroom Bed" states to:
[{'value': False, 'key': 'leftIsInBed'}, {'value': 34, 'key': 'leftPressure'}, {'value': 50, 'key': 'leftSleepNumber'}, {'value': u'<redacted>', 'key': 'leftSleeperId'}, {'value': u'Elizabeth', 'key': 'leftSleeperName'}, {'value': 480, 'key': 'leftSleepGoal'}, {'value': 0, 'key': 'leftAlertId'}, {'value': u'No Alert', 'key': 'leftAlertText'}, {'value': False, 'key': 'rightIsInBed'}, {'value': 96, 'key': 'rightPressure'}, {'value': 40, 'key': 'rightSleepNumber'}, {'value': u'<redacted>', 'key': 'rightSleeperId'}, {'value': u'Nathan', 'key': 'rightSleeperName'}, {'value': 390, 'key': 'rightSleepGoal'}, {'value': 0, 'key': 'rightAlertId'}, {'value': u'No Alert', 'key': 'rightAlertText'}, {'value': False, 'key': 'anyoneInBed'}, {'value': False, 'key': 'onOffState'}, {'value': False, 'key': 'everyoneInBed'}]
   SleepyBed IQ Debug              Stopping device: Bedroom Bed
   SleepyBed IQ Debug              Starting device: Bedroom Bed
   SleepyBed IQ Debug              parseBedData called.
   SleepyBed IQ Debug              parseBedData: Setting device "Bedroom Bed" properties to:
com.nathansheldon.indigoplugin.sleepybed-iq : (dict)
     AllowOnStateChange : false (bool)
     AllowSensorValueChange : false (bool)
     SupportsBatteryLevel : false (bool)
     SupportsOnState : true (bool)
     SupportsSensorValue : false (bool)
     SupportsStatusRequest : true (bool)
     accountId : <redacted> (string)
     address : <redacted> (string)
     base : FlexFit 1 (string)
     bedId : <redacted> (string)
     bedName : Sheldon Bed (string)
     dualSleep : true (bool)
     generation : legacy (string)
     isKidsBed : false (bool)
     macAddress : <redacted> (string)
     model : C2 (string)
     purchaseDate : 2015-02-17T21:25:12Z (string)
     reference : <redacted> (string)
     registrationDate : 2015-03-04T19:39:57Z (string)
     returnRequestStatus : 0 (integer)
     serial :  (string)
     size : None (empty)
     sku : <redacted> (string)
     status : 1 (integer)
     timeZone : US/Pacific (string)
     version :  (string)
     zipCode : <redacted> (string)
   SleepyBed IQ Debug              parseBedData: Setting device "Bedroom Bed" states to:
[{'value': False, 'key': 'leftIsInBed'}, {'value': 34, 'key': 'leftPressure'}, {'value': 50, 'key': 'leftSleepNumber'}, {'value': u'<redacted>', 'key': 'leftSleeperId'}, {'value': u'Elizabeth', 'key': 'leftSleeperName'}, {'value': 480, 'key': 'leftSleepGoal'}, {'value': 0, 'key': 'leftAlertId'}, {'value': u'No Alert', 'key': 'leftAlertText'}, {'value': False, 'key': 'rightIsInBed'}, {'value': 96, 'key': 'rightPressure'}, {'value': 40, 'key': 'rightSleepNumber'}, {'value': u'<redacted>', 'key': 'rightSleeperId'}, {'value': u'Nathan', 'key': 'rightSleeperName'}, {'value': 390, 'key': 'rightSleepGoal'}, {'value': 0, 'key': 'rightAlertId'}, {'value': u'No Alert', 'key': 'rightAlertText'}, {'value': False, 'key': 'anyoneInBed'}, {'value': False, 'key': 'onOffState'}, {'value': False, 'key': 'everyoneInBed'}]
   SleepyBed IQ Debug              Stopping device: Bedroom Bed
   SleepyBed IQ Debug              Starting device: Bedroom Bed


If you don't see that kind of output, then debug logging isn't turned on. Be sure you go to the Plugins menu, then SleepyBed IQ, then Toggle Debugging. You will see "SleepyBed IQ Turning on debug logging" appear in the Indigo log. If you don't then there's something wrong with Indio, or the SleepyBed IQ plugin has become corrupted somehow and will need to be re-installed.

Posted on
Sat Jul 28, 2018 9:33 am
tatrog offline
Posts: 26
Joined: Nov 16, 2013

Re: SleepyBed IQ - Free SleepNumber Bed Monitor Plugin

Things slowed down a bit so figured I would try and work this out. I did re-install the plugin as toggling the debug was producing the same results. Unfortunately that did nothing to resolve the problem. However I did get the following when I did the new config as a result of reload/start over.

Code: Select all
I enter the username/passwd and it verified, click safe and the following results on log file:
Jul 28, 2018 at 11:14:26 AM
   Enabling plugin "SleepyBed IQ 1.1.0"
   Starting plugin "SleepyBed IQ 1.1.0" (pid 1576)
   Started plugin "SleepyBed IQ 1.1.0"
   SleepyBed IQ                    Your plugin version, v1.1.0, is current.
   SleepyBed IQ Error              Unable to connect to the SleepIQ service. Error: 'key'
   SleepyBed IQ Error              Unable to load the list of beds associated with this SleepIQ account. Error: 'key'


I am not able to locate my bad when I add the the bed as a new device, the configuration drop down is empty at this point. However if I reload the plugin I get the following logs (same logs debug on or off):
Code: Select all
l 28, 2018 at 11:26:44 AM
   Reloading plugin "SleepyBed IQ 1.1.0"
   Stopping plugin "SleepyBed IQ 1.1.0" (pid 1576)
   Stopped plugin "SleepyBed IQ 1.1.0"
   Starting plugin "SleepyBed IQ 1.1.0" (pid 1600)
   Started plugin "SleepyBed IQ 1.1.0"
   SleepyBed IQ Error              Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
  File "plugin.py", line 160, in runConcurrentThread
  File "plugin.py", line 464, in parseBedData
AttributeError: 'NoneType' object has no attribute 'data'

   SleepyBed IQ Error              plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)


But now I can see my Bed (Gerry) in the device config drop down. I can execute actions against the bed, set sleep number etc but none of the custom state information is updating and the logs file with the same above code.

Thanks for taking another look.

Posted on
Sat Jul 28, 2018 9:01 pm
nsheldon offline
Posts: 1906
Joined: Aug 09, 2010
Location: CA

Re: SleepyBed IQ - Free SleepNumber Bed Monitor Plugin

Hi.

I need to see the debug log output. Toggling Debugging won't fix the problem, but it'll show me where in the code the problem begins.

The first error clearly indicates that it wasn't able to connect, though that may be intermittent if you're able to send commands to the bed successfully. The second error indicates the plugin isn't getting any data from the SleepIQ service even after connecting. Without the debug logs I cannot tell you any more about the error nor can I attempt to fix it. Please click on the Plugins menu, select SleepyBed IQ then Toggle Debugging. Then go back to the Plugins menu, select SleepyBed IQ then select Reload. Copy the entire log from the point where you reloaded to the point where you see the "AttributeError" message and paste it into your reply. I'll look at the debug logs and see if it's a problem I can fix, or at minimum make the error more helpful.

Who is online

Users browsing this forum: No registered users and 0 guests

cron