在redhat 7系统上工作。pip 等实用程序无法访问互联网。我们让 IT 在系统上安装了新版本的 python 3.8.1,它使用 pip 19.2.3 和 setuptools 41.2.0 成功安装。我们使用这个版本的python来创建一个虚拟环境。在该虚拟环境中,我们使用 pip 从本地存储库安装一组库。
在激活的虚拟环境中,命令类似于:
pip install -r /location/to/our/requirements.txt --no-index --find-links file:///location/of/our/tarballs
执行过程时会出现一些错误字符串,其中包括以下内容:
command: pip install -r /location/to/our/requirements.txt --no-index --find-links file:///location/of/our/tarballs -- 'setuptools >= 40.6.0' wheel
cwd: none
looking in links: /location/of/our/tarballs
Collecting setuptools>=40.6.0
ERROR: Could not find a version that satisfies the requirement setuptools>=40.6.0 (from versions:none)
ERROR: No matching distribution found for setuptools>=40.6.0
谁能解释为什么我们会收到这个错误?
我们运行了 pip list ,它清楚地显示 setuptools 版本高于 40。我缺少某处的配置吗?第一个抛出这个错误的包是 django-bootstrap-3.0.1
pip 19.2.3
setuptools 41.2.0
有趣的笔记:
我们的建筑师在家里运行这个问题为零。
我们在同一个盒子上有一个python3.6版本。可以设置我们的虚拟环境并安装 python3.6 包没有问题。