Update bundled test `setuptools.whl` file
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 66/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- python
- 领域
- build-system
调研方向
从Lib/test/wheeldata/setuptools-79.0.1-py3-none-any.whl和所引用的setuptools变更入手,找出更新后的捆绑wheel版本,该版本不会导入已弃用的typing.AnyStr。检查issue中链接的CPython测试失败,以及PR #150190中的讨论;当捆绑wheel不再在受影响的测试中触发此弃用警告时,任务即告完成。
由索引模型根据 Issue 内容生成。
描述
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: https://github.com/pypa/setuptools/pull/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 https://github.com/python/cpython/pull/150190#discussion_r4400346235
Refs https://github.com/python/cpython/issues/132415
CC @jaraco
- 主要语言
- Python
- 星标
- 77.8k
- 派生
- 37.7k
- 平均合并
- 17 小时 24 分钟
- 30 天内合并 PR
- 716
环境准备
在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
python/cpython 的其他 Issue
-
build OS-unsupported OS-windows type-bug
难度 2/5 1-3 小时 新手友好度 60/100
维护者通常 1 天内回复
-
What's New in 3.12 credits the unstable C API tier to PEP 697 instead of PEP 689可能已有人在做 @TheLouisMahdi 今天认领。 未关闭docs
难度 1/5 1 小时以内 新手友好度 82/100
python/cpython#161078 · 3 条评论 ·
维护者通常 1 天内回复
-
OS-windows type-bug
难度 2/5 1-3 小时 新手友好度 68/100
维护者通常 1 天内回复
-
docs
难度 2/5 1-3 小时 新手友好度 72/100
python/cpython#161007 · 4 条评论 ·
维护者通常 1 天内回复
-
Null dereferencing of a pointer in initconfig.c可能已有人在做 @lazerg 于 3 天前认领。 未关闭interpreter-core topic-C-API type-bug
难度 2/5 1-3 小时 新手友好度 72/100
python/cpython#160962 · 4 条评论 ·
维护者通常 1 天内回复
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
enhancement good first issue
难度 2/5 1-3 小时 新手友好度 78/100
elviskahoro/sdk-python-attio#144 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 84/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
RenyiELBO raises TypeError when model has no sample sites可能已有人在做 @alibb007 今天认领。 未关闭
难度 1/5 1 小时以内 新手友好度 85/100
维护者通常 1 天内回复