[IPython-User] Feature suggestions to ipython notebook

MinRK benjaminrk@gmail....
Wed Sep 11 12:46:30 CDT 2013

On Wed, Sep 11, 2013 at 10:31 AM, Thomas Kluyver <takowl@gmail.com> wrote:

> On 11 September 2013 10:02, Aaron Meurer <asmeurer@gmail.com> wrote:
>> > 5. Jump to the definition of a function (within the same notebook); a
>> > function can be defined many times though.
>> This is a hard problem in general, due to the dynamic nature of
>> python. But libraries like Jedi do a pretty good job.
> Actually, I think it might be fairly easy to jump to the *cell* where a
> function was defined, which is probably good enough for most cases. Each
> cell is executed with a different 'filename' containing its number within
> the session, and code objects created in that cell record that filename:

This is already how `%edit` works when you pass it an interactively defined

> http://nbviewer.ipython.org/6526926
> So you could just parse out the prompt number, and find the corresponding
> cell. Of course, that's not foolproof, e.g. if the cell is merged or split
> after running it.
> Thomas
> _______________________________________________
> IPython-User mailing list
> IPython-User@scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-user
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/ipython-user/attachments/20130911/8e65d7cc/attachment.html 

More information about the IPython-User mailing list