[IPython-dev] [newbie] stepping through code using the 1/0 trick?

Robert Kern robert.kern@gmail....
Thu Jan 7 09:41:11 CST 2010


On 2010-01-07 09:32 AM, Lara Michaels wrote:
> Hi Robert,
>
>
>  > > Is there a way to step through code without importing pdb and using
>  > > set_trace()?
>  >
>  > Why not use set_trace() if you are already inserting exceptions using
> 1/0?
>  >
>  >
>  > import pdb;pdb.set_trace()
>
> But when in ipython I import or %run code with such a set_trace() call I
> get thrown into the normal pdb, not the nicer iPython version that I
> find much more usable.
>
> How can I get into ipython's debugger in a way that I can step through code?

I believe someone is working on adding this ability to 0.11.

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
  that is made terrible by our own mad attempt to interpret it as though it had
  an underlying truth."
   -- Umberto Eco



More information about the IPython-dev mailing list