diff --git a/build-project.py b/build-project.py index 5f7cc204218..2108669ca6f 100755 --- a/build-project.py +++ b/build-project.py @@ -7,13 +7,14 @@ from os import PathLike from pathlib import Path from types import SimpleNamespace +from typing import Union class EnvBuilder(venv.EnvBuilder): """A subclass of venv.EnvBuilder that exposes the python executable command.""" def ensure_directories( - self, env_dir: str | bytes | PathLike[str] | PathLike[bytes] + self, env_dir: Union[str, bytes, "PathLike[str]", "PathLike[bytes]"] ) -> SimpleNamespace: context = super().ensure_directories(env_dir) self.env_exec_cmd = context.env_exec_cmd diff --git a/news/13182.trivial.rst b/news/13182.trivial.rst new file mode 100644 index 00000000000..c2a4d5b79e5 --- /dev/null +++ b/news/13182.trivial.rst @@ -0,0 +1 @@ +Enabling linting rule FA102. diff --git a/pyproject.toml b/pyproject.toml index 5d8dde277be..ed79101bf06 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -184,6 +184,7 @@ select = [ "W", "RUF100", "UP", + "FA102", # future-required-type-annotation ] [tool.ruff.lint.isort]