-
-
Notifications
You must be signed in to change notification settings - Fork 31.4k
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
light.yeelight: catch i/o related exceptions from the backend lib #6952
light.yeelight: catch i/o related exceptions from the backend lib #6952
Conversation
@rytilahti, thanks for your PR! By analyzing the history of the files in this pull request, we identified @HydrelioxGitHub, @jjensn and @BillyNate to be potential reviewers. |
self._bulb.start_flow(flow) | ||
try: | ||
self._bulb.start_flow(flow) | ||
except yeelight.BulbException as ex: |
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.
undefined name 'yeelight'
@@ -255,7 +255,8 @@ def set_default(self) -> None: | |||
def set_flash(self, flash) -> None: | |||
"""Activate flash.""" | |||
if flash: | |||
from yeelight import RGBTransition, SleepTransition, Flow | |||
from yeelight import (RGBTransition, SleepTransition, Flow, |
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.
'yeelight.BulbException' imported but unused
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.
Fixed by forced push, it was used in the prefixed form below in the code.
Fixes/mitigates problems with home-assistant#5949 and home-assistant#6624
f717468
to
8c973ea
Compare
Cherry-picked into the 0.42 branch |
Description:
Fixes/mitigates problems with #5949 and #6624
Related issue (if applicable): fixes #5949 #6624
Checklist:
If the code communicates with devices, web services, or third-party tools:
tox
run successfully. Your PR cannot be merged unless tests passREQUIREMENTS
variable (example).requirements_all.txt
by runningscript/gen_requirements_all.py
..coveragerc
.