From cc596aefbc3c696d9cc21923ed9b385efe617fac Mon Sep 17 00:00:00 2001 From: "Michael J. Sullivan" Date: Wed, 27 Mar 2019 15:10:47 -0700 Subject: [PATCH] Add a type: ignore as a hacky workaround for some mypy bazel issues (#2887) --- stdlib/3/ast.pyi | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/stdlib/3/ast.pyi b/stdlib/3/ast.pyi index a12803342..090d5f8ae 100644 --- a/stdlib/3/ast.pyi +++ b/stdlib/3/ast.pyi @@ -7,7 +7,11 @@ import sys import typing as _typing from typing import Any, Iterator, Optional, Union, TypeVar -from _ast import * +# The same unorthodox Bazel integration causes issues with sys, which +# is imported in both modules. unfortunately we can't just rename sys, +# since mypy only supports version checks with a sys that is named +# sys. +from _ast import * # type: ignore class NodeVisitor(): def visit(self, node: AST) -> Any: ...