Hi, everyone

I'm a new hand at python.

I tried to set system default encoding by using

    "import sys; sys.setdefaultencoding('utf-f')",

but I got error message:

>>> sys.setdefaultencoding('utf-8')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'setdefaultencoding'

Then I checked dir(sys), seems there was no function named
"setdefaultencoding" in "sys" module. But in python's document, it
said I should use sys.setdefaultencoding.

So, my questions: why there is no setdefaultencoding in sys module? if
I want to change system's default encoding, what should I do?

Thanks in advance
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to