diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 5689c826..4ec3cc6b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -14,7 +14,7 @@ repos: - id: trailing-whitespace - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.2.2 + rev: v0.3.2 hooks: - id: ruff args: ["--fix", "--show-fixes"] @@ -27,7 +27,7 @@ repos: args: [--include-version-classifiers, --min-py-version=3.8, --max-py-version=3.12] - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.8.0 + rev: v1.9.0 hooks: - id: mypy name: mypy 3.8 on cibuildwheel/ diff --git a/bin/generate_schema.py b/bin/generate_schema.py index 39012cdc..7a9954a9 100755 --- a/bin/generate_schema.py +++ b/bin/generate_schema.py @@ -290,8 +290,8 @@ schema["properties"] |= oses if args.schemastore: schema["$id"] = "https://json.schemastore.org/partial-cibuildwheel.json" schema["$schema"] = "http://json-schema.org/draft-07/schema#" - schema[ - "description" - ] = "cibuildwheel's toml file, generated with ./bin/generate_schema.py --schemastore from cibuildwheel." + schema["description"] = ( + "cibuildwheel's toml file, generated with ./bin/generate_schema.py --schemastore from cibuildwheel." + ) print(json.dumps(schema, indent=2)) diff --git a/bin/inspect_all_known_projects.py b/bin/inspect_all_known_projects.py index a2c68a6b..ad2c6365 100755 --- a/bin/inspect_all_known_projects.py +++ b/bin/inspect_all_known_projects.py @@ -11,7 +11,6 @@ This will cache the results to all_known_setup.yaml; you can reprint the results without the `--online` setting. """ - from __future__ import annotations import ast diff --git a/bin/update_virtualenv.py b/bin/update_virtualenv.py index d5c86d25..a18c5f7d 100755 --- a/bin/update_virtualenv.py +++ b/bin/update_virtualenv.py @@ -25,9 +25,9 @@ DIR: Final[Path] = Path(__file__).parent.parent.resolve() RESOURCES_DIR: Final[Path] = DIR / "cibuildwheel/resources" GET_VIRTUALENV_GITHUB: Final[str] = "https://github.com/pypa/get-virtualenv" -GET_VIRTUALENV_URL_TEMPLATE: Final[ - str -] = f"{GET_VIRTUALENV_GITHUB}/blob/{{version}}/public/virtualenv.pyz?raw=true" +GET_VIRTUALENV_URL_TEMPLATE: Final[str] = ( + f"{GET_VIRTUALENV_GITHUB}/blob/{{version}}/public/virtualenv.pyz?raw=true" +) @dataclass(frozen=True, order=True) diff --git a/cibuildwheel/__main__.py b/cibuildwheel/__main__.py index 170405a6..9e0f75b8 100644 --- a/cibuildwheel/__main__.py +++ b/cibuildwheel/__main__.py @@ -233,11 +233,9 @@ class PlatformModule(Protocol): # is applied to a module def get_python_configurations( self, build_selector: BuildSelector, architectures: Set[Architecture] - ) -> Sequence[GenericPythonConfiguration]: - ... + ) -> Sequence[GenericPythonConfiguration]: ... - def build(self, options: Options, tmp_path: Path) -> None: - ... + def build(self, options: Options, tmp_path: Path) -> None: ... # pylint: disable-next=inconsistent-return-statements diff --git a/cibuildwheel/extra.py b/cibuildwheel/extra.py index 9e8ae8ec..9cb6dd55 100644 --- a/cibuildwheel/extra.py +++ b/cibuildwheel/extra.py @@ -12,8 +12,7 @@ __all__ = ("Printable", "dump_python_configurations") class Printable(Protocol): - def __str__(self) -> str: - ... + def __str__(self) -> str: ... def dump_python_configurations( diff --git a/cibuildwheel/typing.py b/cibuildwheel/typing.py index 870cf9fc..3fe480aa 100644 --- a/cibuildwheel/typing.py +++ b/cibuildwheel/typing.py @@ -28,5 +28,4 @@ PLATFORMS: Final[set[PlatformName]] = {"linux", "macos", "windows"} class GenericPythonConfiguration(Protocol): @property - def identifier(self) -> str: - ... + def identifier(self) -> str: ... diff --git a/cibuildwheel/util.py b/cibuildwheel/util.py index 18900fc3..fb334257 100644 --- a/cibuildwheel/util.py +++ b/cibuildwheel/util.py @@ -91,8 +91,7 @@ def call( env: Mapping[str, str] | None = None, cwd: PathOrStr | None = None, capture_stdout: Literal[False] = ..., -) -> None: - ... +) -> None: ... @typing.overload @@ -101,8 +100,7 @@ def call( env: Mapping[str, str] | None = None, cwd: PathOrStr | None = None, capture_stdout: Literal[True], -) -> str: - ... +) -> str: ... def call(