From f4b91c4306b68c200a54a53ba872903eed2fcd18 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Tue, 26 Oct 2021 19:45:32 -0400 Subject: [PATCH] Revert "mark a couple of typing-only imports as noqa, to appease pyflakes" This reverts commit 6cc1b8441c0cf7428e52bdf1cd541ea830a4eb83. The latest version of pyflakes learned to detect that correctly. --- mesonbuild/interpreterbase/interpreterbase.py | 4 +--- mesonbuild/mlog.py | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/mesonbuild/interpreterbase/interpreterbase.py b/mesonbuild/interpreterbase/interpreterbase.py index 555db3c87..326204da3 100644 --- a/mesonbuild/interpreterbase/interpreterbase.py +++ b/mesonbuild/interpreterbase/interpreterbase.py @@ -52,9 +52,7 @@ import typing as T import textwrap if T.TYPE_CHECKING: - # T.cast is not handled by flake8 to detect quoted annotation use - # see https://github.com/PyCQA/pyflakes/pull/632 - from ..interpreter import Interpreter # noqa + from ..interpreter import Interpreter HolderMapType = T.Dict[ T.Union[ diff --git a/mesonbuild/mlog.py b/mesonbuild/mlog.py index 20d281757..60bc09eb8 100644 --- a/mesonbuild/mlog.py +++ b/mesonbuild/mlog.py @@ -22,9 +22,7 @@ from contextlib import contextmanager from pathlib import Path if T.TYPE_CHECKING: - # T.Union is not handled by flake8 to detect quoted annotation use (StringProtocol) - # see https://github.com/PyCQA/pyflakes/pull/632 - from ._typing import StringProtocol, SizedStringProtocol # noqa: F401 + from ._typing import StringProtocol, SizedStringProtocol """This is (mostly) a standalone module used to write logging information about Meson runs. Some output goes to screen,