Exceptions and unicode messages
kyosohma at gmail.com
kyosohma at gmail.com
Wed Mar 21 09:27:48 EDT 2007
On Mar 21, 6:03 am, Tuomas <tuomas.vesteri... at pp.inet.fi> wrote:
> This works:
> >>> raise StandardError(u'Wrong type')
> Traceback (most recent call last):
> File "<stdin>", line 1, in ?
> StandardError: Wrong type
>
> but don't in Finnish:
> >>> raise StandardError(u'Väärä tyyppi')
> Traceback (most recent call last):
> File "<stdin>", line 1, in ?
> StandardError>>>
> >>>
>
> Any solution in Python?
>
> TV
You may even need to change you computer's default character set to
make this work. This guy did it for one of his programs:
http://aroberge.blogspot.com/2007/01/unicode-headaches-and-solution.html
Mike
More information about the Python-list
mailing list