From b5268b7121dfb6cb4c311dff8bf4baf854328756 2006-01-25 08:28:47 From: fperez Date: 2006-01-25 08:28:47 Subject: [PATCH] - Small fix to demos to flush stdout on each printed block. --- diff --git a/IPython/demo.py b/IPython/demo.py index 77cb546..7ca26e9 100644 --- a/IPython/demo.py +++ b/IPython/demo.py @@ -242,6 +242,7 @@ class Demo: print marquee('<%s> block # %s (%s remaining)' % (self.fname,index,self.nblocks-index-1)) print self.src_blocks_colored[index], + sys.stdout.flush() def show_all(self): """Show entire demo on screen, block by block""" @@ -257,6 +258,7 @@ class Demo: print marquee('<%s> block # %s (%s remaining)' % (fname,index,nblocks-index-1)) print block, + sys.stdout.flush() def __call__(self,index=None): """run a block of the demo. diff --git a/doc/ChangeLog b/doc/ChangeLog index fe771b5..8b6a9ed 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -1,3 +1,8 @@ +2006-01-25 Fernando Perez + + * IPython/demo.py (Demo.show): Flush stdout after each block, so + computationally intensive blocks don't appear to stall the demo. + 2006-01-24 Ville Vainio * iplib.py, hooks.py: 'result_display' hook can return a non-None