[Nipy-devel] debugging nipype

Yaroslav Halchenko lists@onerussian....
Wed Jan 6 16:45:33 CST 2010

Hi Fernando,

Could you please shine the light: Is %Pprint sufficient to enable
pprint by default while working in IPython interactively?

It seems that I still need to
from IPython.Extensions import ipy_pretty

to enable it

BTW see 



On Wed, 07 Oct 2009, Fernando Perez wrote:

> No, the  __pretty__ support is an extension in case you want to make
> your objects 'pretty-printable'.   In ipython by default,  we use
> pprint from the stdlib, the problem is that pprint is very
> static-type-y: it only pretty prints specific types by doing
> 'issubclass' checks, you can read the code via

> import pprint
> pprint.PrettyPrinter??

> the method that matters is _format.

> One thing you could do is make __repr__ more human-friendly.  Or yes,
> you can upgrade to 0.10, use the __pretty__ extension,  and add
> __pretty__ to Bunch.

=------------------------------   /v\  ----------------------------=
Keep in touch                    // \\     (yoh@|www.)onerussian.com
Yaroslav Halchenko              /(   )\               ICQ#: 60653192
                   Linux User    ^^-^^    [175555]

More information about the Nipy-devel mailing list