From 1d335545b2ce49f4425edc739f3756ada5731983 Mon Sep 17 00:00:00 2001 From: Shantanu <12621235+hauntsaninja@users.noreply.github.com> Date: Sun, 28 Nov 2021 20:01:06 -0800 Subject: [PATCH] _osx_support: fix _read_output (#6436) * _osx_support: fix _read_output * [pre-commit.ci] auto fixes from pre-commit.com hooks Co-authored-by: hauntsaninja <> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- stdlib/_osx_support.pyi | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/stdlib/_osx_support.pyi b/stdlib/_osx_support.pyi index ce1fffc00..024e02d39 100644 --- a/stdlib/_osx_support.pyi +++ b/stdlib/_osx_support.pyi @@ -1,3 +1,4 @@ +import sys from typing import Iterable, Sequence, Tuple, TypeVar _T = TypeVar("_T") @@ -11,7 +12,13 @@ _COMPILER_CONFIG_VARS: Tuple[str, ...] # undocumented _INITPRE: str # undocumented def _find_executable(executable: str, path: str | None = ...) -> str | None: ... # undocumented -def _read_output(commandstring: str) -> str | None: ... # undocumented + +if sys.version_info >= (3, 7): + def _read_output(commandstring: str, capture_stderr: bool = ...) -> str | None: ... # undocumented + +else: + def _read_output(commandstring: str) -> str | None: ... # undocumented + def _find_build_tool(toolname: str) -> str: ... # undocumented _SYSTEM_VERSION: str | None # undocumented