Skip to content
Snippets Groups Projects
Commit 7be784f3 authored by Manuel Jacob's avatar Manuel Jacob
Browse files

py3: add warning about buffering behavior of pycompat.{stdout,stderr}

parent bad37041
No related branches found
No related tags found
No related merge requests found
......@@ -143,6 +143,11 @@
long = int
# Warning: sys.stdout.buffer and sys.stderr.buffer do not necessarily have
# the same buffering behavior as sys.stdout and sys.stderr. The interpreter
# initializes them with block-buffered streams or unbuffered streams (when
# the -u option or the PYTHONUNBUFFERED environment variable is set), never
# with a line-buffered stream.
# TODO: .buffer might not exist if std streams were replaced; we'll need
# a silly wrapper to make a bytes stream backed by a unicode one.
stdin = sys.stdin.buffer
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment