python
module_error
ai_generated
true
ModuleNotFoundError:没有名为 'setuptools' 的模块
ModuleNotFoundError: No module named 'setuptools'
ID: python/setuptools-no-module-named-setuptools
80%修复率
86%置信度
0证据数
2025-11-01首次发现
版本兼容性
| 版本 | 状态 | 引入 | 弃用 | 备注 |
|---|---|---|---|---|
| 3.8 | active | — | — | — |
| 3.9 | active | — | — | — |
根因分析
当前 Python 环境中未安装 setuptools。
English
setuptools is not installed in the current Python environment.
解决方案
-
90% 成功率 Install setuptools via ensurepip
python -m ensurepip --upgrade
-
80% 成功率 Install from source
curl -O https://bootstrap.pypa.io/ez_setup.py && python ez_setup.py
无效尝试
常见但无效的做法:
-
Installing setuptools with pip
30% 失败
May fail if pip is also missing.
-
Using easy_install
50% 失败
Deprecated and may not work.