python2.7中安装依赖包报错:UnicodeDecodeError: ‘ascii’ codec can’t decode byte 0xc2 in position 7: ordinal not in range(128)
解决方案:在python文件夹下(所运行的环境中的python,conda环境中的python在Anaconda3\envs\环境名\python)的Lib\site-packages 建一个文件:sitecustomize.py
内容为:
import sys
sys.setdefaultencoding('gb2312')
保存好后,重新安装!
参考文章:here