UnicodeError: ASCII decoding error: ordinal not in range(128)
Oleg Broytmann
phd at phd.pp.ru
Wed Jan 9 06:36:30 EST 2002
On Wed, Jan 09, 2002 at 12:57:18AM -0800, Brian Quinlan wrote:
> Hrvoje Nezic wrote:
> > I get this error whan I try to use characters above 128.
> > (I am using Python 2.2 on Windows 2000).
> >
> > Python FAQ suggests the following to change
> > the default encoding:
> >
> > import sys
> > sys.setdefaultencoding(encoding)
>
> I can't believe the Python FAQ suggests that! You should stay away from
> that routine (though I'll tell you how to use it later :-).
I wrote this entry in the FAQ, and I really meant it. But I said there,
in the FAQ, that it is valid in sitecustomize.py. Ok, this is valid *only*
in the sitecustomize.py.
Oleg.
--
Oleg Broytmann http://phd.pp.ru/ phd at phd.pp.ru
Programmers don't die, they just GOSUB without RETURN.
More information about the Python-list
mailing list