mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 05:07:41 +00:00
Catch errors in automation (instead of raise unexpected error) in Overkiz (#135026)
Catch errors in automation (instead of raise unexpected error)
This commit is contained in:
parent
48da88583f
commit
802ad55493
@ -6,7 +6,7 @@ from typing import Any, cast
|
|||||||
from urllib.parse import urlparse
|
from urllib.parse import urlparse
|
||||||
|
|
||||||
from pyoverkiz.enums import OverkizCommand, Protocol
|
from pyoverkiz.enums import OverkizCommand, Protocol
|
||||||
from pyoverkiz.exceptions import OverkizException
|
from pyoverkiz.exceptions import BaseOverkizException
|
||||||
from pyoverkiz.models import Command, Device, StateDefinition
|
from pyoverkiz.models import Command, Device, StateDefinition
|
||||||
from pyoverkiz.types import StateType as OverkizStateType
|
from pyoverkiz.types import StateType as OverkizStateType
|
||||||
|
|
||||||
@ -105,7 +105,7 @@ class OverkizExecutor:
|
|||||||
"Home Assistant",
|
"Home Assistant",
|
||||||
)
|
)
|
||||||
# Catch Overkiz exceptions to support `continue_on_error` functionality
|
# Catch Overkiz exceptions to support `continue_on_error` functionality
|
||||||
except OverkizException as exception:
|
except BaseOverkizException as exception:
|
||||||
raise HomeAssistantError(exception) from exception
|
raise HomeAssistantError(exception) from exception
|
||||||
|
|
||||||
# ExecutionRegisteredEvent doesn't contain the device_url, thus we need to register it here
|
# ExecutionRegisteredEvent doesn't contain the device_url, thus we need to register it here
|
||||||
|
Loading…
x
Reference in New Issue
Block a user