[IPython-dev] Re: Changes to Notebook Format

Robert Kern rkern at ucsd.edu
Wed Aug 3 01:13:16 EDT 2005


Fernando Perez wrote:
> Hans Meine wrote:

>> class ErrorStream:
>>    def write(s):
>>       lastCell = {retrieve somehow}
>>       if lastCell.type() == ErrorOutput:
>>   lastCell.append(s)
>>       else:
>>          appendCell(ErrorOutputCell(s))
> 
> That should work, yes.  Nice and simple :)

I still think that this should be a low priority. While recording the 
stdout and stderr outputs properly interleaved is nice and simple, it 
still complicates the document generation and UI.

Any interleaving of stdout and stderr is an accident. The whole point of 
having two different streams is that they can be handled separately and 
piped to two different locations. stderr messages need to be written 
with that in mind for any piece of code. Usually, they are, so I don't 
believe that this is going to be a significant issue in practice.

-- 
Robert Kern
rkern at ucsd.edu

"In the fields of hell where the grass grows high
  Are the graves of dreams allowed to die."
   -- Richard Harter




More information about the IPython-dev mailing list