[MERGE] Workaround buggy pdb.post_mortem.

Andrew Bennetts andrew.bennetts at canonical.com
Tue Feb 3 05:56:41 GMT 2009

I'm not totally sure we want to merge this to trunk, but this patch may be
useful to some developers anyway.  Before Python 2.6, pdb.post_mortem was
buggy if a generator was in the traceback:

This can be pretty frustrating when using BZR_PDB=1, because we're clever
people and use generators a fair bit in bzr!  Robert was bitten by this
today.  So this patch works around the bug, basically by reimplementing what
post_mortem() does, except for the buggy bit :)

It's already fixed in Python's trunk (and I think 2.6), so one option for
frustrated devs is to switch to 2.6 already... but otherwise this patch may
be handy.

For Ubuntu, I've filed a bug,
asking for the fix to be backported.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: pdb-workaround-3979.patch
Type: text/x-diff
Size: 4047 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20090203/5dd8b49e/attachment.bin 

More information about the bazaar mailing list