-1
nano /usr/local/lib/python2.7/site-packages/sitecustomize.py
import sys
reload(sys)
sys.setdefaultencoding('UTF-8')
[email protected]:/home/debian# python
Python 2.7.3 (default, Jan 2 2013, 16:53:07)
[GCC 4.7.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> print sys.getdefaultencoding()
ascii
這是怎麼回事?
http://stackoverflow.com/questions/2276200/changing-default-encoding-of-python – Moj 2013-04-27 11:01:31