From c3051cd3e2181296a023520c7456f8f838ec1425 Mon Sep 17 00:00:00 2001 From: Khaleel Al-Adhami Date: Tue, 29 Oct 2024 10:58:58 -0700 Subject: [PATCH] fake the class name --- reflex/config.py | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/reflex/config.py b/reflex/config.py index db7bb0f6b..1a76625dc 100644 --- a/reflex/config.py +++ b/reflex/config.py @@ -303,23 +303,17 @@ def interpret_env_var_value( ) -class PathMeta(type): - """Metaclass for Path.""" +class ExistingPath(Path): + """A path that must exist.""" - def __getattr__(cls, name): - """Get the attribute from the Path class. - - Args: - name: The attribute name. + @property + def __class__(self): + """Get the class of the path. Returns: - The attribute. + The class of the path. """ - return getattr(Path, name) - - -class ExistingPath(Path, metaclass=PathMeta): - """A path that must exist.""" + return Path @dataclasses.dataclass(init=False)