Yann Dirson added the comment:
> The fact that my stdout object has no read1() and needs the above patch looks
> like a good lead for further investigation?
That's linked to universal_newlines, the bug only shows when that flag is set.
Testcases provided in https://github.com/pyt
Change by Yann Dirson :
--
keywords: +patch
pull_requests: +24542
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/25859
___
Python tracker
<https://bugs.python.org/issu
Yann Dirson added the comment:
Relevant commits include this one from v3.1.4:
commit 877766dee8e60c7971ed0cabba89fbe981c2ab1b
Author: Antoine Pitrou
Date: Sat Mar 19 17:00:37 2011 +0100
Issue #11459: A `bufsize` value of 0 in subprocess.Popen() really creates
unbuffered pipes
Yann Dirson added the comment:
With upcoming 3.10 phasing out 2.7 compatibility I have to find a solution to
this, so I'm back digging here.
Even .read(1) on a subprocess pipe causes an underlying buffered read, so
working around the problem by a loop of 1-byte reads has to do with os
New submission from Yann Dirson :
On a POpen object created with bufsize=0, stdout.readline() does a buffered
reading with python3, whereas in 2.7 it did char-by-char reading. See attached
example.
As a result, a poll including the stdout object suffers a behaviour change when
stdout is