Re: Buffering of sys.stdout and sys.stderr in python3 (and documentation)

2013-11-11 Thread swatkins
It's surprising and broken that stderr should be buffered in python3. python3 calls setvbuf(3) on stderr at startup to achieve this chuckle-headed behavior. It makes stderr line buffered if on a terminal, and fully buffered if redirected to a log file. A fully buffered stderr is a very bad

Re: Buffering of sys.stdout and sys.stderr in python3 (and documentation)

2013-11-11 Thread swatkins
sys.stderr = os.fdopen(sys.stderr.fileno(), 'w', 0) which unfortunately doesn't work! I guess will resort to python3 -u, although I don't want stdout to be unbuffered. -- https://mail.python.org/mailman/listinfo/python-list