mirror of
https://github.com/home-assistant/core.git
synced 2025-06-25 01:21:51 +02:00
Fixed YoLink incorrect valve status (#147021)
* Fix valve status * Fix as suggested
This commit is contained in:
@ -6,5 +6,5 @@
|
||||
"dependencies": ["auth", "application_credentials"],
|
||||
"documentation": "https://www.home-assistant.io/integrations/yolink",
|
||||
"iot_class": "cloud_push",
|
||||
"requirements": ["yolink-api==0.5.2"]
|
||||
"requirements": ["yolink-api==0.5.5"]
|
||||
}
|
||||
|
@ -155,7 +155,10 @@ class YoLinkValveEntity(YoLinkEntity, ValveEntity):
|
||||
@property
|
||||
def available(self) -> bool:
|
||||
"""Return true is device is available."""
|
||||
if self.coordinator.dev_net_type is not None:
|
||||
if (
|
||||
self.coordinator.device.is_support_mode_switching()
|
||||
and self.coordinator.dev_net_type is not None
|
||||
):
|
||||
# When the device operates in Class A mode, it cannot be controlled.
|
||||
return self.coordinator.dev_net_type != ATTR_DEVICE_MODEL_A
|
||||
return super().available
|
||||
|
2
requirements_all.txt
generated
2
requirements_all.txt
generated
@ -3154,7 +3154,7 @@ yeelight==0.7.16
|
||||
yeelightsunflower==0.0.10
|
||||
|
||||
# homeassistant.components.yolink
|
||||
yolink-api==0.5.2
|
||||
yolink-api==0.5.5
|
||||
|
||||
# homeassistant.components.youless
|
||||
youless-api==2.2.0
|
||||
|
2
requirements_test_all.txt
generated
2
requirements_test_all.txt
generated
@ -2598,7 +2598,7 @@ yalexs==8.10.0
|
||||
yeelight==0.7.16
|
||||
|
||||
# homeassistant.components.yolink
|
||||
yolink-api==0.5.2
|
||||
yolink-api==0.5.5
|
||||
|
||||
# homeassistant.components.youless
|
||||
youless-api==2.2.0
|
||||
|
Reference in New Issue
Block a user