-
-
Notifications
You must be signed in to change notification settings - Fork 34.1k
Fix Skybell binary sensor state update #14927
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Skybell binary sensor state update #14927
Conversation
@@ -80,3 +80,5 @@ def update(self): | |||
|
|||
if self._sensor_type == 'chime_level': | |||
self._state = self._device.outdoor_chime_level | |||
else | |||
self._state = STATE_UNKNOWN |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unexpected indentation
@@ -80,3 +80,5 @@ def update(self): | |||
|
|||
if self._sensor_type == 'chime_level': | |||
self._state = self._device.outdoor_chime_level | |||
else |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SyntaxError: invalid syntax
72746f0
to
ed1277c
Compare
Using |
@amelchio Thanks, I didn't know that. I'll remove that commit. |
ed1277c
to
cb0a3d3
Compare
Description:
The
binary_sensor.skybell
platform can fail to update its state when the event list returned by the Skybell API does not have entries for the monitored conditions. This is due to an bug that makes the event listNone
rather than an empty dictionary.Both
binary_sensor.skybell
andsensor.skybell
can also returnNone
instead ofSTATE_UNKNOWN
as their state, this is also fixed.Related issue (if applicable): fixes #14871
Example entry for
configuration.yaml
(if applicable):Checklist:
tox
. Your PR cannot be merged unless tests pass