代码拉取完成,页面将自动刷新
From c6266e423fa26aafa01f1df71de7c6613273155e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@hroncok.cz>
Date: Tue, 14 May 2024 16:24:07 +0200
Subject: [PATCH] Make the validation test for entry-points work with Python
3.13+
The exception in importlib.metadata has changed.
See https://github.com/python/importlib_metadata/issues/488
This makes an existing test pass with Python 3.13.
Partially fixes https://github.com/pypa/setuptools/issues/4196
---
setuptools/_entry_points.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/setuptools/_entry_points.py b/setuptools/_entry_points.py
index 747a69067e..b244e78387 100644
--- a/setuptools/_entry_points.py
+++ b/setuptools/_entry_points.py
@@ -17,7 +17,8 @@ def ensure_valid(ep):
"""
try:
ep.extras
- except AttributeError as ex:
+ except (AttributeError, AssertionError) as ex:
+ # Why both? See https://github.com/python/importlib_metadata/issues/488
msg = (
f"Problems to parse {ep}.\nPlease ensure entry-point follows the spec: "
"https://packaging.python.org/en/latest/specifications/entry-points/"
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。