setvbuf() ??

Roland Schlenker rol9999 at attglobal.net
Thu Mar 29 04:43:29 CEST 2001


Wayne Cuddy wrote:
> 
> I need to print a period on an xterm every few seconds to provide status to the
> user, I don't want to force a newline.  How do I turn off line buffering for
> standard out?

How about:

import sys

sys.stdout.write(".")
sys.stdout.flush()

Roland Schlenker



More information about the Python-list mailing list