From 2686e2006096669313d82de9226e0dc3ba02c29a Mon Sep 17 00:00:00 2001 From: Jon Banafato Date: Wed, 21 Apr 2021 21:48:45 -0400 Subject: [PATCH] Add missing tag attribute to TypeIgnore stub (#5238) This attribute was [added in 3.8]. This change lets mypy resolve the type correctly instead of failing with an attr-defined error. [added in 3.8]: https://github.com/python/cpython/pull/13479 --- stdlib/_ast.pyi | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/stdlib/_ast.pyi b/stdlib/_ast.pyi index 155565290..fd0bc107d 100644 --- a/stdlib/_ast.pyi +++ b/stdlib/_ast.pyi @@ -25,7 +25,8 @@ class mod(AST): ... if sys.version_info >= (3, 8): class type_ignore(AST): ... - class TypeIgnore(type_ignore): ... + class TypeIgnore(type_ignore): + tag: str class FunctionType(mod): argtypes: typing.List[expr] returns: expr