复制虚拟环境报错Fatal Python error: Py_Initialize: Unable to get the locale encoding

报错内容如下:


Could not find platform independent libraries 
Consider setting $PYTHONHOME to [:]
Fatal Python error: Py_Initialize: Unable to get the locale encoding
ImportError: No module named 'encodings'

Current thread 0x00007f1fbac1a740 (most recent call first):

问题出在多个版本python,而python3.5启动时去找encodings时没找到。看了下/usr/local/python3.5/下面有这个包,比对了下其他正常的机器,发现将机器ok的目录中的/usr/local/lib/python3.5 复制过来即可

你可能感兴趣的:(技巧)