[Python-Dev] New-style exceptions

Michael Hudson mwh at python.net
Thu Aug 5 17:32:00 CEST 2004


Tim Peters <tim.peters at gmail.com> writes:

> [Michael Hudson]
> ...
>> Well, it turns out to be a bit big for attaching, so it's here:
>> 
>> http://starship.python.net/crew/mwh/hacks/new-style-exceptions-hacking.diff
>> 
>> This is very much a first cut; no attempt at subtlety.  The procedure
>> went roughly "Hack until it compiles, hack until it doesn't dump core
>> immediately, hack until most tests pass."
>> 
>> The good news: all tests but test_pickletools pass (and that's doomed;
>> just look at it).
>
> Eh?  test_pickletools is a three-line test, which just runs the
> doctests in pickletools.py.  The only exceptions mentioned in the
> latter are the builtin ValueError and OverflowError.  What's the
> problem?

Sorry, was too obscure.  One of the doctests pickles a couple
instances of PicklingError and disassembles the pickle.  That's not
going to stay the same past an old-style/new-style transition.

Cheers,
mwh

-- 
  If a train station is a place where a train stops, what's a
  workstation?                            -- unknown (to me, at least)


More information about the Python-Dev mailing list