From 1f0c4bbf4ad0eb95c0c5b2d3e9a774559c94d051 Mon Sep 17 00:00:00 2001 From: Jim Crist-Harif Date: Mon, 2 Oct 2023 23:49:43 -0500 Subject: [PATCH] Fix `__rich_repr__` type annotation --- msgspec/__init__.pyi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/msgspec/__init__.pyi b/msgspec/__init__.pyi index 6e4937a0..219fc122 100644 --- a/msgspec/__init__.pyi +++ b/msgspec/__init__.pyi @@ -68,7 +68,9 @@ class Struct: weakref: bool = False, dict: bool = False, ) -> None: ... - def __rich_repr__(self) -> Iterable[Tuple[str, Any]]: ... + def __rich_repr__( + self, + ) -> Iterable[Union[Any, Tuple[Any], Tuple[str, Any], Tuple[str, Any, Any]]]: ... def defstruct( name: str,