Skip to content

Commit 237003e

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 9ee4285 commit 237003e

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

micropip/_utils.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -196,22 +196,25 @@ def platform_to_version(platform: str) -> str:
196196
raise ValueError(
197197
f"Wheel abi '{abis_string}' is not supported. Supported abis are 'abi3' and 'cp{version}'."
198198
)
199-
199+
200200
# Check interpreter compatibility
201201
current_version = int(version)
202202
for tag in tags:
203203
try:
204204
wheel_version = int(tag.interpreter.removeprefix("cp"))
205205
# abi3: forward compatible (wheel_version <= current_version)
206206
# non-abi3: exact match required (wheel_version == current_version)
207-
if (tag.abi == "abi3" and wheel_version <= current_version) or \
208-
(tag.abi != "abi3" and wheel_version == current_version):
207+
if (tag.abi == "abi3" and wheel_version <= current_version) or (
208+
tag.abi != "abi3" and wheel_version == current_version
209+
):
209210
return
210211
except ValueError:
211212
continue
212213

213214
interpreters_string = ",".join({tag.interpreter for tag in tags})
214-
raise ValueError(f"Wheel interpreter version '{interpreters_string}' is not supported.")
215+
raise ValueError(
216+
f"Wheel interpreter version '{interpreters_string}' is not supported."
217+
)
215218

216219

217220
def validate_constraints(

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,4 +77,4 @@ warn_unreachable = false
7777

7878
[tool.pytest.ini_options]
7979
testpaths = ["tests"]
80-
norecursedirs = ["micropip/_vendored"]
80+
norecursedirs = ["micropip/_vendored"]

0 commit comments

Comments
 (0)