Skip to content

Commit a7bcce8

Browse files
Bump setuptools to 83.0.* (#15979)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent 323d5a4 commit a7bcce8

9 files changed

Lines changed: 33 additions & 27 deletions

File tree

lib/ts_utils/mypy.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class MypyDistConf(NamedTuple):
2222
# The configuration section in the metadata file looks like the following, with multiple module sections possible
2323
# [mypy-tests]
2424
# [mypy-tests.yaml]
25-
# module_name = "yaml"
25+
# module-name = "yaml"
2626
# [mypy-tests.yaml.values]
2727
# disallow_incomplete_defs = true
2828
# disallow_untyped_defs = true
@@ -39,9 +39,9 @@ def mypy_configuration_from_distribution(distribution: str) -> list[MypyDistConf
3939

4040
def validate_configuration(section_name: str, mypy_section: dict[str, Any]) -> MypyDistConf:
4141
assert isinstance(mypy_section, dict), f"{section_name} should be a section"
42-
module_name = mypy_section.get("module_name")
42+
module_name = mypy_section.get("module-name")
4343

44-
assert module_name is not None, f"{section_name} should have a module_name key"
44+
assert module_name is not None, f"{section_name} should have a module-name key"
4545
assert isinstance(module_name, str), f"{section_name} should be a key-value pair"
4646

4747
assert "values" in mypy_section, f"{section_name} should have a values section"

stubs/setuptools/@tests/stubtest_allowlist.txt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ setuptools._distutils.command.install.INSTALL_SCHEMES
3737
setuptools._distutils.command.install.SCHEME_KEYS
3838
setuptools._distutils.command.install.WINDOWS_SCHEME
3939
setuptools._distutils.command.install_lib.PYTHON_SOURCE_EXTENSION
40+
setuptools._distutils.dir_util.SkipRepeatAbsolutePaths.instance
4041
setuptools._distutils.dist.fix_help_options
4142
setuptools._distutils.extension.read_setup_file
4243
setuptools._distutils.filelist.findall
@@ -52,7 +53,6 @@ setuptools._distutils.sysconfig.parse_config_h
5253
setuptools._distutils.sysconfig.parse_makefile
5354
setuptools._distutils.sysconfig.project_base
5455
setuptools._distutils.sysconfig.python_build
55-
setuptools._distutils.util.is_freethreaded
5656
setuptools._distutils.util.MACOSX_VERSION_VAR
5757

5858
# Missing submodules from setuptools._distutils
@@ -70,9 +70,7 @@ setuptools._distutils.compat.numpy
7070
setuptools._distutils.compat.py39
7171
setuptools._distutils.core
7272
setuptools._distutils.debug
73-
setuptools._distutils.dir_util
7473
setuptools._distutils.fancy_getopt
75-
setuptools._distutils.file_util
7674
setuptools._distutils.log
7775
setuptools._distutils.text_file
7876
setuptools._distutils.version.Version._cmp # abstract method

stubs/setuptools/METADATA.toml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
version = "82.0.*"
1+
version = "83.0.*"
22
upstream-repository = "https://github.com/pypa/setuptools"
33
extra-description = """\
44
Given that `pkg_resources` is typed since `setuptools >= 71.1`, \
@@ -8,4 +8,9 @@ it is no longer included with `types-setuptools`.
88
[tool.stubtest]
99
# darwin is equivalent to linux for OS-specific methods
1010
ci-platforms = ["linux", "win32"]
11-
stubtest-dependencies = ["tomli"]
11+
stubtest-dependencies = ["more_itertools", "tomli"]
12+
13+
# Stubtest fails on trying to run mypy on the source files rather than our stubs
14+
[mypy-tests.distutils]
15+
module-name = "setuptools._distutils.compilers.C.*"
16+
values = { ignore_errors = true }

stubs/setuptools/setuptools/_distutils/command/build.pyi

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class build(Command):
2424
def initialize_options(self) -> None: ...
2525
def finalize_options(self) -> None: ...
2626
def run(self) -> None: ...
27-
def has_pure_modules(self): ...
28-
def has_c_libraries(self): ...
29-
def has_ext_modules(self): ...
30-
def has_scripts(self): ...
27+
def has_pure_modules(self) -> bool: ...
28+
def has_c_libraries(self) -> bool: ...
29+
def has_ext_modules(self) -> bool: ...
30+
def has_scripts(self) -> bool: ...

stubs/setuptools/setuptools/_distutils/command/install.pyi

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@ class install(Command):
1616
install_base: Incomplete
1717
install_platbase: Incomplete
1818
root: str | None
19-
install_purelib: Incomplete
20-
install_platlib: Incomplete
21-
install_headers: Incomplete
19+
install_purelib: str | None
20+
install_platlib: str | None
21+
install_headers: str | None
2222
install_lib: str | None
23-
install_scripts: Incomplete
24-
install_data: Incomplete
23+
install_scripts: str | None
24+
install_data: str | None
2525
install_userbase: Incomplete
2626
install_usersite: Incomplete
2727
compile: Incomplete
@@ -54,7 +54,7 @@ class install(Command):
5454
def create_path_file(self) -> None: ...
5555
def get_outputs(self): ...
5656
def get_inputs(self): ...
57-
def has_lib(self): ...
58-
def has_headers(self): ...
59-
def has_scripts(self): ...
60-
def has_data(self): ...
57+
def has_lib(self) -> bool: ...
58+
def has_headers(self) -> bool: ...
59+
def has_scripts(self) -> bool: ...
60+
def has_data(self) -> bool: ...

stubs/setuptools/setuptools/_distutils/compilers/C/base.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ class Compiler:
7171

7272
def library_dir_option(self, dir: str) -> str: ...
7373
def library_option(self, lib: str) -> str: ...
74-
def runtime_library_dir_option(self, dir: str) -> str: ...
74+
def runtime_library_dir_option(self, dir: str) -> str | list[str]: ...
7575
def set_executables(self, **kwargs: str) -> None: ...
7676
def set_executable(self, key: str, value) -> None: ...
7777
def compile(

stubs/setuptools/setuptools/_distutils/dist.pyi

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ from re import Pattern
44
from typing import IO, ClassVar, Literal, TypeAlias, TypeVar, overload
55

66
from .cmd import Command
7+
from .extension import Extension
78

89
command_re: Pattern[str]
910

@@ -78,18 +79,18 @@ class Distribution:
7879
script_args: list[str] | None
7980
command_options: dict[str, dict[str, tuple[str, str]]]
8081
dist_files: list[tuple[str, str, str]]
81-
packages: Incomplete
82+
packages: list[str] | None
8283
package_data: dict[str, list[str]]
83-
package_dir: Incomplete
84-
py_modules: Incomplete
84+
package_dir: dict[str, str] | None
85+
py_modules: list[str] | None
8586
libraries: Incomplete
8687
headers: Incomplete
87-
ext_modules: Incomplete
88+
ext_modules: list[Extension] | None
8889
ext_package: Incomplete
8990
include_dirs: Incomplete
9091
extra_path: Incomplete
9192
scripts: Incomplete
92-
data_files: Incomplete
93+
data_files: list[str | tuple[Incomplete, ...]] | None
9394
password: str
9495
command_obj: dict[str, Command]
9596
have_run: dict[str, bool]

stubs/setuptools/setuptools/_distutils/util.pyi

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,4 @@ def byte_compile(
3131
) -> None: ...
3232
def rfc822_escape(header: str) -> str: ...
3333
def is_mingw() -> bool: ...
34+
def is_freethreaded() -> bool: ...
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
def decompose(path): ...
2+
def normalize(text): ...
23
def filesys_decode(path): ...
34
def try_encode(string, enc): ...

0 commit comments

Comments
 (0)