呆鸟的Python数据分析

使用pipenv出现utf-8不能decode的问题

2018-10-11  本文已影响54人  违规昵称不予展示

报错:UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb6 in position 0: invalid start byte

这是我的报错:
F:\fisher>pipenv install
Traceback (most recent call last):
File "f:\python3\lib\runpy.py", line 193, in run_module_as_main
"main", mod_spec)
File "f:\python3\lib\runpy.py", line 85, in run_code
exec(code, run_globals)
File "F:\python3\Scripts\pipenv.exe_main
.py", line 5, in <module>
File "f:\python3\lib\site-packages\pipenv_init
.py", line 23, in <module>
from .cli import cli
File "f:\python3\lib\site-packages\pipenv\cli_init.py", line 3, in <module>
from .command import cli
File "f:\python3\lib\site-packages\pipenv\cli\command.py", line 7, in <module>
import crayons
File "f:\python3\lib\site-packages\pipenv\patched\crayons.py", line 48, in <module>
is_powershell = "powershell" in shellingham.detect_shell()[0]
File "f:\python3\lib\site-packages\pipenv\vendor\shellingham_init
.py", line 22, in detect_shell
shell = get_shell(pid, max_depth=max_depth)
File "f:\python3\lib\site-packages\pipenv\vendor\shellingham\nt.py", line 100, in get_shell
processes = dict(_iter_process())
File "f:\python3\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 0xb6 in position 0: invalid start byte

首先提醒大家不是路径有中文的问题,所以卸载重装一个英文路径是没有用的,别问我是怎么知道的TVT(这不可能)

在网上找了好多方法,都试了,然而没啥用,但是到最后我的操作过程是

不过最后想了一下好像可能也许是执行pip install setuptools==34.3.3这一句的功劳

上一篇 下一篇

猜你喜欢

热点阅读