当我执行python脚本,就会出现此问题:
'import site' failed; use -v for traceback
所以我-v选项又试了一次,而且我可以得到这些信息:
'import site' failed; traceback:
Traceback (most recent call last):
File "/usr/lib/python2.6/site.py", line 513, in <module>
main()
File "/usr/lib/python2.6/site.py", line 495, in main
known_paths = addusersitepackages(known_paths)
File "/usr/lib/python2.6/site.py", line 238, in addusersitepackages
USER_BASE = env_base if env_base else joinuser("~", ".local")
File "/usr/lib/python2.6/site.py", line 225, in joinuser
return os.path.expanduser(os.path.join(*args))
File "/usr/lib/python2.6/posixpath.py", line 256, in expanduser
userhome = pwd.getpwuid(os.getuid()).pw_dir
KeyError: 'getpwuid(): uid not found: 65530'
我该如何处理这种情况呢?