[IPython-user] ipapi rehaul

Ville Vainio vivainio at gmail.com
Tue Jan 24 15:14:11 CST 2006

On 1/24/06, Fernando Perez <Fernando.Perez at colorado.edu> wrote:

> Ville is already aware of this, but just so you can make his work a little
> easier, please use non-decorator syntax on all code that we can include in

True. I'm removing the decorator syntax for now from ipapi. I'm also
refactoring ipapi a little bit, I'm moving the thing into a class so a
single api object always points to the same IPython shell instance.
The usage is pretty much the same, apart from the first line; instead

import IPython.ipapi as ip

You write

import IPython.ipapi
ip = IPython.ipapi.get()

There will be other ways to get the API object, but this is the simple
config file/extension way. get() always gets the api object for most
recently instantiated IPython shell, which is typically the one
importing the extension (for now).

It's not in the SVN yet, though.

Ville Vainio - http://tinyurl.com/2prnb

More information about the IPython-user mailing list