pipenv安装软件包失败

时间:2018-10-10 09:14:31

标签: pip pipenv

我正在尝试使用Pipfilepipenv安装软件包,但是我不断收到错误,我不知道如何调试。

pip --version
pip 18.1

pipenv --version
version 2018.10.9

我得到的错误是:

pipenv install --dev --deploy

Courtesy Notice: Pipenv found itself running within a virtual environment, so it will automatically use that environment, instead of creating its own for any project. You can set PIPENV_IGNORE_VIRTUALENVS=1 to force pipenv to ignore that environment and create its own instead. You can set PIPENV_VERBOSITY=-1 to suppress this warning.
Installing dependencies from Pipfile.lock (917af8)…
An error occurred while installing backports-ssl-match-hostname==3.5.0.1 --hash=sha256:502ad98707319f4a51fa2ca1c677bd659008d27ded9f6380c79e8932e38dcdf2! Will try again.
     ▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉ 185/185 — 00:00:33
Installing initially failed dependencies…
Collecting backports-ssl-match-hostname==3.5.0.1 :00

  Could not find a version that satisfies the requirement backports-ssl-match-hostname==3.5.0.1 (from -r /tmp/pipenv-qlbc3amj-requirements/pipenv-akfm2pt_-requirement.txt (line 1)) (from versions: )
No matching distribution found for backports-ssl-match-hostname==3.5.0.1 (from -r /tmp/pipenv-qlbc3amj-requirements/pipenv-akfm2pt_-requirement.txt (line 1))

  ☤  ▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉▉ 0/1 — 00

看看Pipfile.lock,我发现backports包定义为:

   "backports.ssl-match-hostname": {
        "hashes": [
            "sha256:502ad98707319f4a51fa2ca1c677bd659008d27ded9f6380c79e8932e38dcdf2"
        ],
        "version": "==3.5.0.1"
    },

使用verbose标志运行所有程序,backports程序包是recurlyPipfile的依赖项:

 recurly = ">=2.8.6"

1 个答案:

答案 0 :(得分:0)

在pipenv shell处于活动状态时,将pip版本降级到18.0.0

python -m pip install pip==18.0.0

对我有用