[IPython-dev] Extensible pretty-printing

Brian Granger ellisonbg at gmail.com
Thu Oct 28 18:56:12 EDT 2010

On Thu, Oct 28, 2010 at 3:41 PM, Fernando Perez <fperez.net at gmail.com> wrote:
> On Thu, Oct 28, 2010 at 2:16 PM, Robert Kern <robert.kern at gmail.com> wrote:
>> Yes. The original pull request just tried to restore the status quo
>> anterefactor. It happened to use the CommandChainDispatcher because that was the
>> extensible API at the time. Since the larger issue of what the extensible API
>> *should* be was raised, I am now proposing that we should use pretty.py and
>> expose it as the API for people to extend the string representation used in the
>> displayhook.
> OK, it all makes sense now.  Having looked at extensions/pretty in
> more detail now, I'm happy following through with your suggestion,
> modulo perhaps updating to the most current pretty if we have a stale
> one (I  didn't check yet).
> One last question: we don't want anything actually *printing*, instead
> we want an interface that *returns* strings which we'll  stuff on the
> pyout channel (an in-process version can simply take these values and
> print them, of course).  Right now we only have a single
> representation stored in the 'data' field.  How do you think we should
> go about the multi-field option, within the  context of pretty?

I should mention that this issue of the display hook actually doing
the printing itself was part of why I disabled the pretty extension in
the first place.


> Cheers,
> f
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev

Brian E. Granger, Ph.D.
Assistant Professor of Physics
Cal Poly State University, San Luis Obispo
bgranger at calpoly.edu
ellisonbg at gmail.com

More information about the IPython-dev mailing list