From d69ec9c352f44ec90db932c9766ca749c9e2e023 Mon Sep 17 00:00:00 2001 From: Mathieu Broillet Date: Sat, 1 Jun 2024 14:44:00 +0200 Subject: [PATCH] disable blocking update if bluetooth devices retrieval fails --- custom_components/easy_computer_manager/utils.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/custom_components/easy_computer_manager/utils.py b/custom_components/easy_computer_manager/utils.py index 816c664..5b793d3 100644 --- a/custom_components/easy_computer_manager/utils.py +++ b/custom_components/easy_computer_manager/utils.py @@ -502,7 +502,9 @@ def get_bluetooth_devices(connection: Connection, only_connected: bool = False, if is_unix_system(connection): result = connection.run(commands["unix"]) if result.return_code != 0: - raise HomeAssistantError(f"Could not get Bluetooth devices on system running at {connection.host}.") + _LOGGER.error(f"Could not get Bluetooth devices on system running at {connection.host}.") + return [] + # raise HomeAssistantError(f"Could not get Bluetooth devices on system running at {connection.host}.") devices = [] current_device = {}