[IPython-dev] Multiple outputs per input line

Robert Kern robert.kern at gmail.com
Mon Mar 14 14:44:01 EDT 2011

On 3/14/11 12:20 PM, Thomas Kluyver wrote:
> OK, once again, code:
> https://github.com/takluyver/ipython/commit/0c7eb96f95bbe19b30171d9a51262ec4a01656f0
> As Robert suggests, this keeps only the last of several outputs in Out / _oh in
> the user namespace, while keeping all outputs to be retrieved by %hist. Again,
> I've done fairly superficial tests.

I'm not sure what you are doing here. Out/_oh should be storing the actual 
objects. The history should be storing the formatted text from the displayhook; 
you should not try to use repr() on those objects afterwards. That records the 
wrong thing.

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