From 5162c536c88c4bf46ab74ef09a51165597e90d49 Mon Sep 17 00:00:00 2001 From: Jukka Lehtosalo Date: Tue, 10 Mar 2020 12:15:20 +0000 Subject: [PATCH] Make attributes of inspect.ArgSpec optional in Python 3 (#3838) This makes them consistent with Python 2 stubs. The attributes are documented here: https://docs.python.org/3/library/inspect.html#inspect.getargspec --- stdlib/3/inspect.pyi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stdlib/3/inspect.pyi b/stdlib/3/inspect.pyi index 65fe700c3..9696067cc 100644 --- a/stdlib/3/inspect.pyi +++ b/stdlib/3/inspect.pyi @@ -175,8 +175,8 @@ def getclasstree(classes: List[type], unique: bool = ...) -> Any: ... class ArgSpec(NamedTuple): args: List[str] - varargs: str - keywords: str + varargs: Optional[str] + keywords: Optional[str] defaults: Tuple[Any, ...] class Arguments(NamedTuple):