Skip to content

Commit a8a41c6

Browse files
authored
Merge branch 'main' into generate-distuttils-stubs-on-install
2 parents 96932c5 + 7308942 commit a8a41c6

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,8 @@ check = [
117117

118118
# local
119119

120-
# Removal of deprecated UP027, PT004 & PT005 astral-sh/ruff#14383
121-
"ruff >= 0.8.0; sys_platform != 'cygwin'",
120+
# Deprecated rules must now be selected by exact rule code
121+
"ruff >= 0.13.0; sys_platform != 'cygwin'",
122122
]
123123

124124
cover = [
@@ -138,7 +138,7 @@ type = [
138138
# pin mypy version so a new version doesn't suddenly cause the CI to fail,
139139
# until types-setuptools is removed from typeshed.
140140
# For help with static-typing issues, or mypy update, ping @Avasam
141-
"mypy==1.14.*",
141+
"mypy==1.18.*",
142142
# Typing fixes in version newer than we require at runtime
143143
"importlib_metadata>=7.0.2; python_version < '3.10'",
144144
# Imported unconditionally in tools/finalize.py

ruff.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,14 +65,14 @@ ignore = [
6565
"TRY003", # raise-vanilla-args, avoid multitude of exception classes
6666
"TRY301", # raise-within-try, it's handy
6767
"UP015", # redundant-open-modes, explicit is preferred
68-
"UP038", # Using `X | Y` in `isinstance` call is slower and more verbose https://github.com/astral-sh/ruff/issues/7871
6968
# Only enforcing return type annotations for public functions
7069
"ANN202", # missing-return-type-private-function
7170
]
7271

7372
[lint.per-file-ignores]
7473
# Suppress nuisance warnings about module-import-not-at-top-of-file (E402) due to workaround for #4476
7574
"setuptools/__init__.py" = ["E402"]
75+
# pkg_resources is due for removal, not worth fixing existing errors
7676
"pkg_resources/__init__.py" = ["E402", "ANN204"]
7777
"pkg_resources/tests/test_resources.py" = ["PT031"]
7878

setuptools/build_meta.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,9 @@ def _find_info_directory(self, metadata_directory: StrPath, suffix: str) -> Path
357357
candidates = [f for f in dirs if f.endswith(suffix)]
358358

359359
if len(candidates) != 0 or len(dirs) != 1:
360-
assert len(candidates) == 1, f"Multiple {suffix} directories found"
360+
assert len(candidates) == 1, (
361+
f"Exactly one {suffix} should have been produced, but found {len(candidates)}: {candidates}"
362+
)
361363
return Path(parent, candidates[0])
362364

363365
msg = f"No {suffix} directory found in {metadata_directory}"

0 commit comments

Comments
 (0)