using pdb and catching exception

Amit Gupta emailamit at gmail.com
Mon Dec 3 18:36:52 EST 2007


On Dec 3, 11:10 am, Amit Gupta <emaila... at gmail.com> wrote:
>
>
> Thanks Frank. But again, this results into stack-track when the
> exception is caught. On the other hand, I would like the debug-trace
> just before throwing the exception. As a case, I might be debugging
> code, where the programmar forgot to handle an exception and it is
> being caught way up in the flow (with generic catch block)

One thing that I can guess is to put a breakpoint on function "raise".
I assume all of the exceptions are thrown by "raise" and raise is not
a keyword, instead a function.

Will it work?



More information about the Python-list mailing list