10BC0 Bump setuptools to 80.7.* by Avasam · Pull Request #14069 · python/typeshed · GitHub
[go: up one dir, main page]

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions stubs/setuptools/METADATA.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
version = "80.4.*"
version = "80.7.*"
upstream_repository = "https://github.com/pypa/setuptools"
extra_description = """\
Given that `pkg_resources` is typed since `setuptools >= 71.1`, \
it is no longer included with `types-setuptools`.
"""
requires = ["setuptools"] # For pkg_resources

[tool.stubtest]
# darwin is equivalent to linux for OS-specific methods
Expand Down
1 change: 0 additions & 1 deletion stubs/setuptools/setuptools/__init__.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ class Command(_Command):
distribution: Distribution
# Any: Dynamic command subclass attributes
def __init__(self, dist: Distribution, **kw: Any) -> None: ...
def ensure_string_list(self, option: str) -> None: ...
# Note: Commands that setuptools doesn't re-expose are considered deprecated (they must be imported from distutils directly)
# So we're not listing them here. This list comes directly from the setuptools/command folder. Minus the test command.
@overload # type: ignore[override]
Expand Down
2 changes: 1 addition & 1 deletion stubs/setuptools/setuptools/command/bdist_egg.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class bdist_egg(Command):
user_options: ClassVar[list[tuple[str, str | None, str]]]
boolean_options: ClassVar[list[str]]
bdist_dir: Incomplete
plat_name: Incomplete
plat_name: str
keep_temp: bool
dist_dir: Incomplete
skip_build: bool
Expand Down
1 change: 0 additions & 1 deletion stubs/setuptools/setuptools/command/build_ext.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ have_rtld: bool
use_stubs: bool
libtype: str

def if_dl(s): ...
def get_abi3_suffix(): ...

class build_ext(_build_ext):
Expand Down
3 changes: 2 additions & 1 deletion stubs/setuptools/setuptools/dist.pyi
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from _typeshed import Incomplete, StrPath
from collections.abc import Iterable, Iterator, MutableMapping
from importlib import metadata
from typing import Literal, TypeVar, overload

from . import Command, SetuptoolsDeprecationWarning
Expand Down Expand Up @@ -39,7 +40,7 @@ class Distribution(_Distribution):
setup_requires: list[str]
def __init__(self, attrs: MutableMapping[str, Incomplete] | None = None) -> None: ...
def parse_config_files(self, filenames: Iterable[StrPath] | None = None, ignore_option_errors: bool = False) -> None: ...
def fetch_build_eggs(self, requires: str | Iterable[str]): ...
def fetch_build_eggs(self, requires: str | Iterable[str]) -> list[metadata.Distribution]: ...
def get_egg_cache_dir(self) -> str: ...
def fetch_build_egg(self, req): ...
# NOTE: Commands that setuptools doesn't re-expose are considered deprecated (they must be imported from distutils directly)
Expand Down
18 changes: 16 additions & 2 deletions stubs/setuptools/setuptools/installer.pyi
Original file line number Diff line number Diff line change
@@ -1,2 +1,16 @@
def fetch_build_egg(dist, req): ...
def strip_marker(req): ...
from importlib import metadata
from typing import Any
from typing_extensions import deprecated

@deprecated(
"""
`setuptools.installer` and `fetch_build_eggs` are deprecated.
Requirements should be satisfied by a PEP 517 installer.
If you are using pip, you can try `pip install --use-pep517`.
"""
)
def fetch_build_egg(dist, req) -> metadata.Distribution | metadata.PathDistribution: ...

# Returns packaging.requirements.Requirement
# But since this module is deprecated, we avoid declaring a dependency on packaging
def strip_marker(req) -> Any: ...
0