From d0d39eeb5c7def7ef1ecd51211b0e9318e33e457 Mon Sep 17 00:00:00 2001 From: Khaleel Al-Adhami Date: Mon, 21 Oct 2024 18:22:39 -0700 Subject: [PATCH] add types to error boundary --- reflex/components/base/error_boundary.py | 4 +++- reflex/components/base/error_boundary.pyi | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/reflex/components/base/error_boundary.py b/reflex/components/base/error_boundary.py index b35c69a60..83becc034 100644 --- a/reflex/components/base/error_boundary.py +++ b/reflex/components/base/error_boundary.py @@ -12,7 +12,9 @@ from reflex.state import FrontendEventExceptionState from reflex.vars.base import Var -def on_error_spec(error: Var, info: Var[Dict[str, str]]) -> Tuple[Var[str], Var[str]]: +def on_error_spec( + error: Var[Dict[str, str]], info: Var[Dict[str, str]] +) -> Tuple[Var[str], Var[str]]: """The spec for the on_error event handler. Args: diff --git a/reflex/components/base/error_boundary.pyi b/reflex/components/base/error_boundary.pyi index 94b129bdc..c84742851 100644 --- a/reflex/components/base/error_boundary.pyi +++ b/reflex/components/base/error_boundary.pyi @@ -11,7 +11,7 @@ from reflex.style import Style from reflex.vars.base import Var def on_error_spec( - error: Var, info: Var[Dict[str, str]] + error: Var[Dict[str, str]], info: Var[Dict[str, str]] ) -> Tuple[Var[str], Var[str]]: ... class ErrorBoundary(Component):