mirror of
https://github.com/home-assistant/core.git
synced 2025-11-10 03:19:34 +00:00
Enable strict typing on script helper (#122075)
This commit is contained in:
@@ -34,7 +34,7 @@ class TraceElement:
|
||||
"""Container for trace data."""
|
||||
self._child_key: str | None = None
|
||||
self._child_run_id: str | None = None
|
||||
self._error: Exception | None = None
|
||||
self._error: BaseException | None = None
|
||||
self.path: str = path
|
||||
self._result: dict[str, Any] | None = None
|
||||
self.reuse_by_child = False
|
||||
@@ -52,7 +52,7 @@ class TraceElement:
|
||||
self._child_key = child_key
|
||||
self._child_run_id = child_run_id
|
||||
|
||||
def set_error(self, ex: Exception) -> None:
|
||||
def set_error(self, ex: BaseException | None) -> None:
|
||||
"""Set error."""
|
||||
self._error = ex
|
||||
|
||||
|
||||
Reference in New Issue
Block a user