diff --git a/homeassistant/components/august/__init__.py b/homeassistant/components/august/__init__.py index e8b4a15b65a..53ea583050b 100644 --- a/homeassistant/components/august/__init__.py +++ b/homeassistant/components/august/__init__.py @@ -259,13 +259,14 @@ class AugustData(AugustSubscriberMixin): device_id, ) - async def async_lock_async(self, device_id): + async def async_lock_async(self, device_id, hyper_bridge): """Lock the device but do not wait for a response since it will come via pubnub.""" return await self._async_call_api_op_requires_bridge( device_id, self._api.async_lock_async, self._august_gateway.access_token, device_id, + hyper_bridge, ) async def async_unlock(self, device_id): @@ -277,13 +278,14 @@ class AugustData(AugustSubscriberMixin): device_id, ) - async def async_unlock_async(self, device_id): + async def async_unlock_async(self, device_id, hyper_bridge): """Unlock the device but do not wait for a response since it will come via pubnub.""" return await self._async_call_api_op_requires_bridge( device_id, self._api.async_unlock_async, self._august_gateway.access_token, device_id, + hyper_bridge, ) async def _async_call_api_op_requires_bridge( diff --git a/homeassistant/components/august/lock.py b/homeassistant/components/august/lock.py index ea977a3c2d0..3c5af4c94c9 100644 --- a/homeassistant/components/august/lock.py +++ b/homeassistant/components/august/lock.py @@ -39,17 +39,22 @@ class AugustLock(AugustEntityMixin, RestoreEntity, LockEntity): self._attr_unique_id = f"{self._device_id:s}_lock" self._update_from_data() + @property + def _hyper_bridge(self): + """Check if the lock has a paired hyper bridge.""" + return bool(self._detail.bridge and self._detail.bridge.hyper_bridge) + async def async_lock(self, **kwargs): """Lock the device.""" if self._data.activity_stream.pubnub.connected: - await self._data.async_lock_async(self._device_id) + await self._data.async_lock_async(self._device_id, self._hyper_bridge) return await self._call_lock_operation(self._data.async_lock) async def async_unlock(self, **kwargs): """Unlock the device.""" if self._data.activity_stream.pubnub.connected: - await self._data.async_unlock_async(self._device_id) + await self._data.async_unlock_async(self._device_id, self._hyper_bridge) return await self._call_lock_operation(self._data.async_unlock) diff --git a/homeassistant/components/august/manifest.json b/homeassistant/components/august/manifest.json index 15b31edcce4..db537287b05 100644 --- a/homeassistant/components/august/manifest.json +++ b/homeassistant/components/august/manifest.json @@ -2,7 +2,7 @@ "domain": "august", "name": "August", "documentation": "https://www.home-assistant.io/integrations/august", - "requirements": ["yalexs==1.1.18"], + "requirements": ["yalexs==1.1.19"], "codeowners": ["@bdraco"], "dhcp": [ { diff --git a/requirements_all.txt b/requirements_all.txt index 89285ae67f0..86e575f4cb5 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -2466,7 +2466,7 @@ xs1-api-client==3.0.0 yalesmartalarmclient==0.3.4 # homeassistant.components.august -yalexs==1.1.18 +yalexs==1.1.19 # homeassistant.components.yeelight yeelight==0.7.8 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 2e62c9f62d9..9827fb3f7b7 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -1464,7 +1464,7 @@ xmltodict==0.12.0 yalesmartalarmclient==0.3.4 # homeassistant.components.august -yalexs==1.1.18 +yalexs==1.1.19 # homeassistant.components.yeelight yeelight==0.7.8