【问题标题】:Pip3 gives "No matching distribution found for ..." errorPip3 给出“没有找到...的匹配分布”错误
【发布时间】:2017-12-03 08:36:26
【问题描述】:

我有一个 reqs.txt 文件,其中包含我需要在第二台计算机上安装的许多 python 要求。该文件如下所示:

alabaster==0.7.9
anaconda-client==1.6.0
anaconda-navigator==1.4.3
astroid==1.4.9
astropy==1.3
Babel==2.3.4
backports.shutil-get-terminal-size==1.0.0
beautifulsoup4==4.5.3
bitarray==0.8.1
blaze==0.10.1
...

我正在使用

 pip3 install -r reqs.txt --requirement=reqs.txt

我得到了

me@pc:~$ pip3 install -r reqs.txt --requirement=reqs.txt
Collecting alabaster==0.7.9 (from -r reqs.txt (line 1))
Using cached alabaster-0.7.9-py2.py3-none-any.whl
Collecting anaconda-client==1.6.0 (from -r reqs.txt (line 2))
Could not find a version that satisfies the requirement anaconda-client==1.6.0 (from -r reqs.txt (line 2)) (from versions: 1.1.1, 1.2.2)
No matching distribution found for anaconda-client==1.6.0 (from -r reqs.txt (line 2))

对于该 reqs.txt 文件中的每个包。有任何想法吗?

编辑:reqs.txt 文件是用pip freeze 创建的。即使我删除了版本号,它们仍然不会安装。但是,如果我做一个

pip3 install alabaster

它会毫无问题地安装。

【问题讨论】:

    标签: python-3.x pip python-module


    【解决方案1】:

    雪花石膏的安装没有问题,但是anaconda-client 在 1.6.0 中不可用,使用 pip3 可能在您的原始环境中您有 Anaconda 的独立安装,因此它的版本更优越。因此,使pip3 install -r reqs.txt 不起作用,您可以将版本降级为 pip 中可用的版本,或者在运行命令之前在第二台计算机上安装conda 环境。

    【讨论】:

      猜你喜欢
      • 2017-05-05
      • 1970-01-01
      • 2020-12-15
      • 2021-11-18
      • 2020-12-09
      • 2021-03-12
      • 1970-01-01
      • 2021-07-20
      • 2020-09-16
      相关资源
      最近更新 更多