[PyQt] Exceptions and stack frames
jeremy at jeremysanders.net
Fri Aug 20 10:18:46 BST 2010
Phil Thompson wrote:
> Isn't this the normal behaviour? The stack frame is part of the traceback
> of the exception. It will stay around until it is replaced by another
> If you add a second button to the first dialog that also raises an
> exception, you should see that the __del__ method is called when the
> second exception is raised. There should only ever be one stack frame
> hanging around.
Sorry - I had no idea this was the normal behaviour - I missed this in the
I've worked around my problem by raising a special exception in the
exception handler after handling the first, then ignoring it - urgh.
I tried using exc_clear() instead, but this doesn't seem to have any effect.
I noticed this problem because Python signals seem to continue to be
connected to a QObject even if the Qt part has been deleted, unlike C++
More information about the PyQt