[Python-Dev] [Python-checkins] cpython: Close #17828: better handling of codec errors

Nick Coghlan ncoghlan at gmail.com
Fri Nov 15 12:11:07 CET 2013


On 15 November 2013 17:22, Stefan Behnel <stefan_ml at behnel.de> wrote:
>
> I can't see any bit of information being added by chaining the exceptions
> in this specific case.
>
> Remember that each change to exception messages and/or exception chaining
> will break someone's doctests somewhere, and it's really ugly to work
> around chained exceptions in (cross-Py-version) doctests.
>
> I understand that this is helpful *in general*, though, i.e. for other
> kinds of exceptions in codecs, so maybe changing the exception handling in
> the doctest module could be a work-around for this kind of change?

IIRC, doctest ignores the traceback contents by default - this is just
a bug where the chaining is also triggering for the initial codec
lookup when it should avoid doing that.

Created http://bugs.python.org/issue19609

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia


More information about the Python-Dev mailing list