On Thu, 10 Feb 2011 08:35:24 +, John O'Hagan wrote:
But I'm still a little curious as to why even unsuccessfully attempting
to reassign stdout seems to stop the pipe buffer from filling up.
It doesn't. If the server continues to run, then it's ignoring/handling
both SIGPIPE and the
On Fri, 11 Feb 2011, Nobody wrote:
On Thu, 10 Feb 2011 08:35:24 +, John O'Hagan wrote:
But I'm still a little curious as to why even unsuccessfully
attempting to reassign stdout seems to stop the pipe buffer from
filling up.
It doesn't. If the server continues to run, then it's
On Wed, 9 Feb 2011, Nobody wrote:
On Fri, 04 Feb 2011 15:48:55 +, John O'Hagan wrote:
But I'm still a little curious as to why even unsuccessfully attempting
to reassign stdout seems to stop the pipe buffer from filling up.
It doesn't. If the server continues to run, then it's
On Fri, 04 Feb 2011 15:48:55 +, John O'Hagan wrote:
But I'm still a little curious as to why even unsuccessfully attempting to
reassign stdout seems to stop the pipe buffer from filling up.
It doesn't. If the server continues to run, then it's ignoring/handling
both SIGPIPE and the EPIPE
On Thu, 3 Feb 2011, Nobody wrote:
On Tue, 01 Feb 2011 08:30:19 +, John O'Hagan wrote:
I can't keep reading because that will block - there won't be any more
output until I send some input, and I don't want it in any case.
To try to fix this I added:
proc.stdout = os.path.devnull
On Tue, 01 Feb 2011 08:30:19 +, John O'Hagan wrote:
I can't keep reading because that will block - there won't be any more
output until I send some input, and I don't want it in any case.
To try to fix this I added:
proc.stdout = os.path.devnull
which has the effect of stopping the
I'm starting a server process as a subprocess. Startup is slow and
unpredictable (around 3-10 sec), so I'm reading from its stdout until I get a
line that tells me it's ready before proceeding, in simplified form:
import subprocess
proc = subprocess.Popen(['server', 'args'],
On Tue, Feb 1, 2011 at 12:30 AM, John O'Hagan m...@johnohagan.com wrote:
I'm starting a server process as a subprocess. Startup is slow and
unpredictable (around 3-10 sec), so I'm reading from its stdout until I get a
line that tells me it's ready before proceeding, in simplified form:
import
On Tue, 1 Feb 2011, Chris Rebert wrote:
On Tue, Feb 1, 2011 at 12:30 AM, John O'Hagan m...@johnohagan.com wrote:
I'm starting a server process as a subprocess. Startup is slow and
unpredictable (around 3-10 sec), so I'm reading from its stdout until I
get a line that tells me it's ready
On Tue, 1 Feb 2011, John O'Hagan wrote:
So far my best bet seems to be closing stdin, which doesn't seem very
clean, but it does what I want and seems to be just as fast as using
stdin=open(os.devnull) in the Popen call in the first place.
...and both references to stdin above should have
10 matches
Mail list logo