返回

pipenv安装报错

发布时间:2023-01-03 11:52:35 336
# python# windows

环境

  • CentOS Linux release 7.7.1908 (Core)
  • Python 3.6.8(yum安装的)
  • ​​pipenv​​ 2022.4.20

报错

# pipenv install
Creating a virtualenv for this project...
Pipfile: /root/aa/Pipfile
Using /usr/bin/python3 (3.6.8) to create virtualenv...
⠴ Creating virtual environment...created virtual environment CPython3.6.8.final.0-64 in 247ms
creator CPython3Posix(dest=/root/.local/share/virtualenvs/aa-U57avQvB, clear=False, no_vcs_ignore=False, global=False)
seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/root/.local/share/virtualenv)
added seed packages: pip==21.3.1, setuptools==59.6.0, wheel==0.37.1
activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator
✔ Successfully created virtual environment!
Virtualenv location: /root/.local/share/virtualenvs/aa-U57avQvB
Creating a Pipfile for this project...
Traceback (most recent call last):
File "/usr/local/bin/pipenv", line 8, in
sys.exit(cli())
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 1128, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/cli/options.py", line 56, in main
return super().main(*args, **kwargs, windows_expand_args=False)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 1053, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 1659, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 1395, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 754, in invoke
return __callback(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/decorators.py", line 84, in new_func
return ctx.invoke(f, obj, *args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 754, in invoke
return __callback(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/cli/command.py", line 241, in install
site_packages=state.site_packages,
File "/usr/local/lib/python3.6/site-packages/pipenv/core.py", line 1972, in do_install
site_packages=site_packages,
File "/usr/local/lib/python3.6/site-packages/pipenv/core.py", line 594, in ensure_project
system=system_or_exists,
File "/usr/local/lib/python3.6/site-packages/pipenv/core.py", line 296, in ensure_pipfile
project.create_pipfile(python=python)
File "/usr/local/lib/python3.6/site-packages/pipenv/project.py", line 682, in create_pipfile
from .vendor.pip_shims.shims import InstallCommand
ImportError: cannot import name 'InstallCommand'

解决

pip3 install pipenv==2022.3.23 -i https://pypi.doubanio.com/simple/

特别声明:以上内容(图片及文字)均为互联网收集或者用户上传发布,本站仅提供信息存储服务!如有侵权或有涉及法律问题请联系我们。
举报
评论区(0)
按点赞数排序
用户头像
精选文章
thumb 中国研究员首次曝光美国国安局顶级后门—“方程式组织”
thumb 俄乌线上战争,网络攻击弥漫着数字硝烟
thumb 从网络安全角度了解俄罗斯入侵乌克兰的相关事件时间线