[Python-Dev] Internationalization Toolkit
Tim Peters
tim_one@email.msn.com
Fri, 12 Nov 1999 00:04:44 -0500
[MAL]
>>> Codecs should raise an UnicodeError in case the conversion is
>>> not possible.
[Fred L. Drake, Jr.]
>> I think that should be ValueError, or UnicodeError should be a
>> subclass of ValueError.
>> (Can the -X interpreter option be removed yet?)
[MAL]
> Doesn't Python convert class exceptions to strings when -X is
> used ? I would guess that many scripts already rely on the class
> based mechanism (much of my stuff does for sure), so by the time
> 1.6 is out, I think -X should be considered an option to run
> pre 1.5 code rather than using it for performance reasons.
-X is a red herring. That is, do what seems best without regard for -X. I
already added one subclass exception to the CVS tree (UnboundLocalError as a
subclass of NameError), and in doing that had to figure out how to make it
do the right thing under -X too. It's a bit clumsy to arrange, but not a
problem.