[新人求教] 无法创建 pipenv 虚拟环境

2018-11-24 15:30:14 +08:00
 15874103329
安装好 pipenv 后在 cmd 输入:pipenv install 显示如下:
Traceback (most recent call last):
File "c:\programdata\anaconda3\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "c:\programdata\anaconda3\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\ProgramData\Anaconda3\Scripts\pipenv.exe\__main__.py", line 5, in <module>
File "c:\programdata\anaconda3\lib\site-packages\pipenv\__init__.py", line 47, in <module>
from .cli import cli
File "c:\programdata\anaconda3\lib\site-packages\pipenv\cli\__init__.py", line 3, in <module>
from .command import cli
File "c:\programdata\anaconda3\lib\site-packages\pipenv\cli\command.py", line 7, in <module>
import crayons
File "c:\programdata\anaconda3\lib\site-packages\pipenv\patched\crayons.py", line 49, in <module>
is_powershell = "powershell" in shellingham.detect_shell()[0]
File "c:\programdata\anaconda3\lib\site-packages\pipenv\vendor\shellingham\__init__.py", line 22, in detect_shell
shell = get_shell(pid, max_depth=max_depth)
File "c:\programdata\anaconda3\lib\site-packages\pipenv\vendor\shellingham\nt.py", line 100, in get_shell
processes = dict(_iter_process())
File "c:\programdata\anaconda3\lib\site-packages\pipenv\vendor\shellingham\nt.py", line 78, in _iter_process
info = {'executable': str(pe.szExeFile.decode('utf-8'))}
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd7 in position 0: invalid continuation byte

求老哥们帮帮忙
4446 次点击
所在节点    Python
7 条回复
e2541
2018-11-24 15:51:55 +08:00
pip 和 pipenv 是什么版本
15874103329
2018-11-24 16:02:26 +08:00
pipenv==2018.11.14
pip 18.1 from c:\programdata\anaconda3\lib\site-packages\pip (python 3.7)
Sylv
2018-11-24 17:27:39 +08:00
八成和终端的编码有关系。
LokiSharp
2018-11-24 17:48:54 +08:00
初学别用 windows 调平台就要半天,不装 vs 一堆包要手动装
likuku
2018-11-24 18:20:51 +08:00
要么换 virtualenv 试试呢
buildblock
2018-11-25 03:41:53 +08:00
装一个 docker 或者 bash on ubuntu 吧 之前在 Windows 下搞环境真是要把我玩吐血了…像我这种老鸟都受不鸟,初学者就更别说了…
Eds1995
2018-11-25 17:19:16 +08:00
看一下 locale 设置

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/511105

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX