[IPython-dev] History
Robert Kern
robert.kern at gmail.com
Mon Feb 21 15:31:37 EST 2011
On 2/19/11 3:54 PM, Thomas Kluyver wrote:
> On 18 February 2011 22:10, Robert Kern <robert.kern at gmail.com
> <mailto:robert.kern at gmail.com>> wrote:
>
> This sounds fine. With (session, line) as the foreign key, it seems
> straightforward to keep it synchronous. The only suggestion I would make is to
> make the store_inputs() method (and a putative store_outputs() method) take the
> execution_count explicitly rather than taking it from the shell.
>
>
> Basic implementation here:
> https://github.com/takluyver/ipython/commit/15fbffa0d924765461c9a1d539d49daf70bc5315
>
> The only bit missing is that I don't know off the top of my head where to call
> the store_outputs method. I can have a dig in the code, or if someone would like
> to point me to the best place, I'd be grateful. In the meantime, I've tried
> calling the function manually, and it works as expected.
The DisplayHook.log_output() method would be the right place to do it.
Eventually, it would be nice to expand this to capture all of the different
formats and the printed outputs, but just storing the text/plain format for
displayhook'ed objects is enough for now.
--
Robert Kern
"I have come to believe that the whole world is an enigma, a harmless enigma
that is made terrible by our own mad attempt to interpret it as though it had
an underlying truth."
-- Umberto Eco
More information about the IPython-dev
mailing list