Fix untrapped exceptions during Yale Access Bluetooth first setup (#88642)

pull/88979/head
J. Nick Koston 2023-02-23 02:18:55 -05:00 committed by Paulus Schoutsen
parent 35142e456a
commit 951df3df57
5 changed files with 9 additions and 7 deletions

View File

@ -28,5 +28,5 @@
"documentation": "https://www.home-assistant.io/integrations/august",
"iot_class": "cloud_push",
"loggers": ["pubnub", "yalexs"],
"requirements": ["yalexs==1.2.7", "yalexs_ble==2.0.2"]
"requirements": ["yalexs==1.2.7", "yalexs_ble==2.0.3"]
}

View File

@ -1,6 +1,8 @@
"""The Yale Access Bluetooth integration."""
from __future__ import annotations
import asyncio
from yalexs_ble import (
AuthError,
ConnectionInfo,
@ -62,7 +64,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
await push_lock.wait_for_first_update(DEVICE_TIMEOUT)
except AuthError as ex:
raise ConfigEntryAuthFailed(str(ex)) from ex
except YaleXSBLEError as ex:
except (YaleXSBLEError, asyncio.TimeoutError) as ex:
raise ConfigEntryNotReady(
f"{ex}; Try moving the Bluetooth adapter closer to {local_name}"
) from ex

View File

@ -12,5 +12,5 @@
"dependencies": ["bluetooth_adapters"],
"documentation": "https://www.home-assistant.io/integrations/yalexs_ble",
"iot_class": "local_push",
"requirements": ["yalexs-ble==2.0.2"]
"requirements": ["yalexs-ble==2.0.3"]
}

View File

@ -2670,13 +2670,13 @@ xs1-api-client==3.0.0
yalesmartalarmclient==0.3.9
# homeassistant.components.yalexs_ble
yalexs-ble==2.0.2
yalexs-ble==2.0.3
# homeassistant.components.august
yalexs==1.2.7
# homeassistant.components.august
yalexs_ble==2.0.2
yalexs_ble==2.0.3
# homeassistant.components.yeelight
yeelight==0.7.10

View File

@ -1895,13 +1895,13 @@ xmltodict==0.13.0
yalesmartalarmclient==0.3.9
# homeassistant.components.yalexs_ble
yalexs-ble==2.0.2
yalexs-ble==2.0.3
# homeassistant.components.august
yalexs==1.2.7
# homeassistant.components.august
yalexs_ble==2.0.2
yalexs_ble==2.0.3
# homeassistant.components.yeelight
yeelight==0.7.10