7

当我尝试 pipinstall pipenv 时,出现以下错误:

nathan@DESKTOP-KKB4QL2:/mnt/c/Users/Nathan/Dropbox$ pip install pipenv
Downloading/unpacking pipenv
  Downloading pipenv-11.7.1.tar.gz (5.0MB): 5.0MB downloaded
  Running setup.py (path:/tmp/pip_build_nathan/pipenv/setup.py) egg_info for package pipenv
    error in pipenv setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers
    Complete output from command python setup.py egg_info:
    error in pipenv setup command: 'install_requires' must be a string or list of strings containing valid project/version requirement specifiers

----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_nathan/pipenv
Storing debug log for failure in /home/nathan/.pip/pip.log

我试图更新 pip,但这只是导致异常。

4

1 回答 1

9

确保您使用的是正确版本的 pip。很可能您的 pip 默认为 2.7,您可以尝试 pip3.6 或在您的系统中找到任何/所有版本的 pip。

我尝试时遇到了这个确切的问题

pip install --user pipenv

当我尝试时已修复(在 MacOS sierra 上)

sudo -H pip3.6 install -U pipenv

谢谢

于 2018-03-14T14:51:54.310 回答