Repository navigation
Update bundled test setuptools.whl file #160824
Copy link
Copy link
Open
Labels
dependenciesPull requests that update a dependency filePull requests that update a dependency fileinfraCI, GitHub Actions, buildbots, Dependabot, etc.CI, GitHub Actions, buildbots, Dependabot, etc.topic-ensurepip
Description
File: https://github.com/python/cpython/blob/main/Lib/test/wheeldata/setuptools-79.0.1-py3-none-any.whl
Why the update is needed?
- We want to deprecate
typing.AnyStr, which in older versions ofsetuptoolsit was used indistutilsbundled withsetuptools: Removetyping.AnyStrusage pypa/setuptools#5232 - It now fails tests with a new deprecation warning https://github.com/python/cpython/actions/runs/40683617713/job/122801165319?pr=150190
======================================================================
ERROR: test_syntax_error_for_string (test.test_peg_generator.test_c_parser.TestCParser.test_syntax_error_for_string)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/runner/work/cpython/cpython-ro-srcdir/Lib/test/test_peg_generator/test_c_parser.py", line 121, in setUp
cmd = support.missing_compiler_executable()
File "/home/runner/work/cpython/cpython-ro-srcdir/Lib/test/support/__init__.py", line 2218, in missing_compiler_executable
from setuptools._distutils import ccompiler, sysconfig
File "/home/runner/work/cpython/cpython-builddir/build/test_python_61704æ/tempcwd/venv/lib/python3.16/site-packages/setuptools/_distutils/ccompiler.py", line 1, in <module>
from .compat.numpy import ( # noqa: F401
...<2 lines>...
)
File "/home/runner/work/cpython/cpython-builddir/build/test_python_61704æ/tempcwd/venv/lib/python3.16/site-packages/setuptools/_distutils/compat/numpy.py", line 2, in <module>
from ..compilers.C.base import _default_compilers, compiler_class # noqa: F401
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/runner/work/cpython/cpython-builddir/build/test_python_61704æ/tempcwd/venv/lib/python3.16/site-packages/setuptools/_distutils/compilers/C/base.py", line 34, in <module>
from ...util import execute, is_mingw, split_quoted
File "/home/runner/work/cpython/cpython-builddir/build/test_python_61704æ/tempcwd/venv/lib/python3.16/site-packages/setuptools/_distutils/util.py", line 20, in <module>
from typing import TYPE_CHECKING, AnyStr
File "/home/runner/work/cpython/cpython-ro-srcdir/Lib/typing.py", line 3950, in __getattr__
warnings._deprecated(
~~~~~~~~~~~~~~~~~~~~^
"typing.AnyStr",
^^^^^^^^^^^^^^^^
...<5 lines>...
remove=(3, 21),
^^^^^^^^^^^^^^^
)
^
File "/home/runner/work/cpython/cpython-ro-srcdir/Lib/_py_warnings.py", line 893, in _deprecated
_wm.warn(msg, DeprecationWarning, stacklevel=stacklevel)
~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
DeprecationWarning: 'typing.AnyStr' is deprecated and slated for removal in Python 3.21. Use PEP 695 type parameters with constraints instead
The other option is to ignore this warning in all places where we import setuptools.
Refs #150190 (comment)
Refs #132415
CC @jaraco
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
dependenciesPull requests that update a dependency filePull requests that update a dependency fileinfraCI, GitHub Actions, buildbots, Dependabot, etc.CI, GitHub Actions, buildbots, Dependabot, etc.topic-ensurepip
Activity