From ee7fa96f6d4c81347cbdab3e6afcedc882a03433 Mon Sep 17 00:00:00 2001 From: Henry Schreiner Date: Wed, 2 Oct 2024 00:22:40 -0400 Subject: [PATCH] chore: remove a couple of things pylint is unhappy about (#2027) Signed-off-by: Henry Schreiner --- cibuildwheel/__main__.py | 1 - cibuildwheel/options.py | 7 +++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/cibuildwheel/__main__.py b/cibuildwheel/__main__.py index 6d97cdc67..973c48a86 100644 --- a/cibuildwheel/__main__.py +++ b/cibuildwheel/__main__.py @@ -271,7 +271,6 @@ def get_python_configurations( def build(self, options: Options, tmp_path: Path) -> None: ... -# pylint: disable-next=inconsistent-return-statements def get_platform_module(platform: PlatformName) -> PlatformModule: if platform == "linux": return cibuildwheel.linux diff --git a/cibuildwheel/options.py b/cibuildwheel/options.py index 66da2ad49..5e1e71d16 100644 --- a/cibuildwheel/options.py +++ b/cibuildwheel/options.py @@ -307,7 +307,6 @@ def _resolve_cascade( return result -# pylint: disable-next=inconsistent-return-statements def _apply_inherit_rule( before: str | None, after: str, rule: InheritRule, option_format: OptionFormat | None ) -> str: @@ -329,10 +328,10 @@ def _apply_inherit_rule( if rule == InheritRule.APPEND: return option_format.merge_values(before, after) - elif rule == InheritRule.PREPEND: + if rule == InheritRule.PREPEND: return option_format.merge_values(after, before) - else: - assert_never(rule) + + assert_never(rule) def _stringify_setting(