Bump pyHomee to 1.2.5 (#136567)

This commit is contained in:
Markus Adrario 2025-01-26 13:48:35 +00:00 committed by GitHub
parent 7044771876
commit a9f14ce174
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 9 additions and 9 deletions

View File

@ -51,14 +51,14 @@ async def async_setup_entry(hass: HomeAssistant, entry: HomeeConfigEntry) -> boo
entry.runtime_data = homee
entry.async_on_unload(homee.disconnect)
async def _connection_update_callback(connected: bool) -> None:
def _connection_update_callback(connected: bool) -> None:
"""Call when the device is notified of changes."""
if connected:
_LOGGER.warning("Reconnected to Homee at %s", entry.data[CONF_HOST])
else:
_LOGGER.warning("Disconnected from Homee at %s", entry.data[CONF_HOST])
await homee.add_connection_listener(_connection_update_callback)
homee.add_connection_listener(_connection_update_callback)
# create device register entry
device_registry = dr.async_get(hass)

View File

@ -38,7 +38,7 @@ class HomeeEntity(Entity):
self._attribute.add_on_changed_listener(self._on_node_updated)
)
self.async_on_remove(
await self._entry.runtime_data.add_connection_listener(
self._entry.runtime_data.add_connection_listener(
self._on_connection_changed
)
)
@ -56,7 +56,7 @@ class HomeeEntity(Entity):
def _on_node_updated(self, attribute: HomeeAttribute) -> None:
self.schedule_update_ha_state()
async def _on_connection_changed(self, connected: bool) -> None:
def _on_connection_changed(self, connected: bool) -> None:
self._host_connected = connected
self.schedule_update_ha_state()
@ -93,7 +93,7 @@ class HomeeNodeEntity(Entity):
"""Add the homee binary sensor device to home assistant."""
self.async_on_remove(self._node.add_on_changed_listener(self._on_node_updated))
self.async_on_remove(
await self._entry.runtime_data.add_connection_listener(
self._entry.runtime_data.add_connection_listener(
self._on_connection_changed
)
)
@ -142,6 +142,6 @@ class HomeeNodeEntity(Entity):
def _on_node_updated(self, node: HomeeNode) -> None:
self.schedule_update_ha_state()
async def _on_connection_changed(self, connected: bool) -> None:
def _on_connection_changed(self, connected: bool) -> None:
self._host_connected = connected
self.schedule_update_ha_state()

View File

@ -8,5 +8,5 @@
"iot_class": "local_push",
"loggers": ["homee"],
"quality_scale": "bronze",
"requirements": ["pyHomee==1.2.3"]
"requirements": ["pyHomee==1.2.5"]
}

2
requirements_all.txt generated
View File

@ -1763,7 +1763,7 @@ pyEmby==1.10
pyHik==0.3.2
# homeassistant.components.homee
pyHomee==1.2.3
pyHomee==1.2.5
# homeassistant.components.rfxtrx
pyRFXtrx==0.31.1

View File

@ -1452,7 +1452,7 @@ pyDuotecno==2024.10.1
pyElectra==1.2.4
# homeassistant.components.homee
pyHomee==1.2.3
pyHomee==1.2.5
# homeassistant.components.rfxtrx
pyRFXtrx==0.31.1