Skip to content

Commit b8ec8aa

Browse files
committed
require types-setuptools>=75.2.0
this is necessary to have python/typeshed#12791
1 parent e4eb663 commit b8ec8aa

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

.ci/requirements-mypy.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@ sphinx
99
types-atheris
1010
types-defusedxml
1111
types-olefile
12-
types-setuptools
12+
types-setuptools>=75.2.0

setup.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,12 @@
1616
import sys
1717
import warnings
1818
from collections.abc import Iterator
19-
from typing import Any
19+
from typing import Any, TYPE_CHECKING
2020

2121
from setuptools import Extension, setup
2222
from setuptools.command.build_ext import build_ext
23+
if TYPE_CHECKING:
24+
from setuptools import _BuildInfo
2325

2426

2527
def get_version() -> str:
@@ -1001,7 +1003,7 @@ def debug_build() -> bool:
10011003
return hasattr(sys, "gettotalrefcount") or FUZZING_BUILD
10021004

10031005

1004-
libraries = [
1006+
libraries: list[tuple[str, _BuildInfo]] = [
10051007
("pil_imaging_mode", {"sources": ["src/libImaging/Mode.c"]}),
10061008
]
10071009

0 commit comments

Comments
 (0)