diff --git a/stgpytools/types/generic.py b/stgpytools/types/generic.py index 24a657b..81caf3f 100644 --- a/stgpytools/types/generic.py +++ b/stgpytools/types/generic.py @@ -28,7 +28,7 @@ class MissingTBase(Enum): DataType = Union[str, bytes, bytearray, SupportsString] -FuncExceptT = str | Callable[..., Any] | tuple[Callable[..., Any] | str, str] # type: ignore +FuncExceptT = str | Callable[..., Any] | tuple[Callable[..., Any] | str, str] """ This type is used in specific functions that can throw an exception. ``` @@ -45,8 +45,6 @@ def some_func() -> None: ``ValueError: (some_func) Some error occurred!!`` """ -FuncExceptT = str | Callable[..., Any] | tuple[Callable[..., Any] | str, str] # type: ignore - StrArr = SingleOrArr[SupportsString] StrArrOpt = SingleOrArrOpt[SupportsString] diff --git a/stgpytools/types/utils.py b/stgpytools/types/utils.py index 97918db..a591ac4 100644 --- a/stgpytools/types/utils.py +++ b/stgpytools/types/utils.py @@ -191,16 +191,16 @@ def _wrapper(function: Callable[Concatenate[T0, P0], R0]) -> inject_self[T0, P0, return _wrapper -class inject_self(Generic[T, P, R], inject_self_base[T, P, R]): # type: ignore +class inject_self(Generic[T, P, R], inject_self_base[T, P, R]): """Wrap a method so it always has a constructed ``self`` provided to it.""" - class cached(Generic[T0, P0, R0], inject_self_base[T0, P0, R0]): # type: ignore + class cached(Generic[T0, P0, R0], inject_self_base[T0, P0, R0]): """ Wrap a method so it always has a constructed ``self`` provided to it. Once ``self`` is constructed, it will be reused. """ - class init_kwargs(Generic[T0, P0, R0], inject_self_base[T0, P0, R0]): # type: ignore + class init_kwargs(Generic[T0, P0, R0], inject_self_base[T0, P0, R0]): """ Wrap a method so it always has a constructed ``self`` provided to it. When constructed, kwargs to the function will be passed to the constructor.