Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
gh-146444: Make Platforms/Apple/ compatible with Python 3.9
Replace "str | None" with typing.Union[str, None].
  • Loading branch information
vstinner committed Mar 30, 2026
commit 31d843c80441bfa879829bac368583f85ee0e96b
3 changes: 2 additions & 1 deletion Platforms/Apple/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,10 @@
from os.path import basename, relpath
from pathlib import Path
from subprocess import CalledProcessError
from typing import Union

EnvironmentT = dict[str, str]
ArgsT = Sequence[str | Path]
ArgsT = Sequence[Union[str, Path]]

SCRIPT_NAME = Path(__file__).name
PYTHON_DIR = Path(__file__).resolve().parent.parent.parent
Expand Down
3 changes: 2 additions & 1 deletion Platforms/Apple/testbed/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import subprocess
import sys
from pathlib import Path
from typing import Union

TEST_SLICES = {
"iOS": "ios-arm64_x86_64-simulator",
Expand Down Expand Up @@ -262,7 +263,7 @@ def update_test_plan(testbed_path, platform, args):

def run_testbed(
platform: str,
simulator: str | None,
simulator: Union[str, None],
args: list[str],
verbose: bool = False,
):
Expand Down
Loading