Re: Fast jump to error lines?

Thomas Kluyver <[email protected]> Wed, 24 Jun 2015 11:48:44 -0700
Newsgroups gmane.comp.python.ipython.user
Message-ID <CAOvn4qhROWtcTvcchPPjGn+0CNxZgfp=oAc9=Z0hSirhPrUuug@mail.gmail.com>
--===============1088727156==
Content-Type: multipart/alternative; boundary=001a113cd73c8d83f3051947f660

--001a113cd73c8d83f3051947f660
Content-Type: text/plain; charset=UTF-8

On 24 June 2015 at 05:42, Charles Fox <[email protected]> wrote:

> Could it be done as a magic or does it need changes to IPython code itself?
>

I haven't thought through all the details, but I think you can do it as a
magic.

sys.last_traceback is a good idea, but that might get overwritten by
exceptions raised and handled within IPython's machinery. It looks like
get_ipython().InteractiveTB.tb (if that exists) is a reference to the last
traceback shown to the user.

Thomas

--001a113cd73c8d83f3051947f660
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_extra"><div class=3D"gmail_quote">On 2=
4 June 2015 at 05:42, Charles Fox <span dir=3D"ltr">&lt;<a href=3D"mailto:c=
[email protected]" target=3D"_blank">[email protected]</a>&gt;</span=
> wrote:<br><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;bo=
rder-left:1px #ccc solid;padding-left:1ex"><div>Could it be done as a magic=
 or does it need changes to IPython code itself?<br></div></blockquote></di=
v><br></div><div class=3D"gmail_extra">I haven&#39;t thought through all th=
e details, but I think you can do it as a magic.<br><br></div><div class=3D=
"gmail_extra">sys.last_traceback is a good idea, but that might get overwri=
tten by exceptions raised and handled within IPython&#39;s machinery. It lo=
oks like get_ipython().InteractiveTB.tb (if that exists) is a reference to =
the last traceback shown to the user.<br><br></div><div class=3D"gmail_extr=
a">Thomas<br></div></div>

--001a113cd73c8d83f3051947f660--

--===============1088727156==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
IPython-User mailing list
[email protected]
http://mail.scipy.org/mailman/listinfo/ipython-user

--===============1088727156==--