python
install_error
ai_generated
true
RuntimeError: Setuptools 版本 58.0.0 太旧,无法使用 pyproject.toml 构建系统。最低要求是 60.0.0。
RuntimeError: Setuptools version 58.0.0 is too old to use the pyproject.toml build system. Minimum required is 60.0.0.
ID: python/setuptools-version-mismatch
80%修复率
85%置信度
0证据数
2024-06-05首次发现
版本兼容性
| 版本 | 状态 | 引入 | 弃用 | 备注 |
|---|---|---|---|---|
| 3.8 | active | — | — | — |
| 3.9 | active | — | — | — |
| 3.10 | active | — | — | — |
| 3.11 | active | — | — | — |
| 3.12 | active | — | — | — |
根因分析
安装的 setuptools 版本不支持 pyproject.toml 中定义的构建系统。
English
The installed setuptools version does not support the build system defined in pyproject.toml.
解决方案
-
95% 成功率 Upgrade setuptools to a compatible version
pip install --upgrade setuptools>=60.0.0
-
90% 成功率 Use a virtual environment with a newer Python version
python3.11 -m venv venv && source venv/bin/activate && pip install setuptools
无效尝试
常见但无效的做法:
-
Downgrading pip
90% 失败
The issue is with setuptools, not pip; downgrading pip does not help.
-
Removing pyproject.toml
70% 失败
setuptools may fall back to setup.py, but modern packages rely on pyproject.toml.