From 1f58cea824b67d84c671f8d3a3cec9eb5c17fe79 Mon Sep 17 00:00:00 2001 From: Tom Close Date: Wed, 4 Sep 2024 15:33:11 +1000 Subject: [PATCH] removed troublesome class_getitem from mtime_cached_property --- fileformats/core/typing.py | 8 +++++++- fileformats/core/utils.py | 2 -- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/fileformats/core/typing.py b/fileformats/core/typing.py index d7de7b6..c3bc219 100644 --- a/fileformats/core/typing.py +++ b/fileformats/core/typing.py @@ -22,4 +22,10 @@ PathType: TypeAlias = ty.Union[str, Path] -__all__ = ["CryptoMethod", "FspathsInputType", "PathType", "TypeAlias", "Self"] +__all__ = [ + "CryptoMethod", + "FspathsInputType", + "PathType", + "TypeAlias", + "Self", +] diff --git a/fileformats/core/utils.py b/fileformats/core/utils.py index 45a42d2..2221343 100644 --- a/fileformats/core/utils.py +++ b/fileformats/core/utils.py @@ -300,5 +300,3 @@ def __get__( value = self.func(instance) instance.__dict__[self._cache_name] = (instance.mtimes, value) return value - - __class_getitem__ = classmethod(ty.GenericAlias) # type: ignore[attr-defined, var-annotated]