Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #54420 > unrolled thread

Re: subprocess call is not waiting.

Started by"harish.barvekar@gmail.com" <hbarvekar@ciphercloud.com>
First post2013-09-19 04:42 -0700
Last post2013-09-19 15:58 -0400
Articles 2 — 2 participants

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: subprocess call is not waiting. "harish.barvekar@gmail.com" <hbarvekar@ciphercloud.com> - 2013-09-19 04:42 -0700
    Re: subprocess call is not waiting. Terry Reedy <tjreedy@udel.edu> - 2013-09-19 15:58 -0400

#54420 — Re: subprocess call is not waiting.

From"harish.barvekar@gmail.com" <hbarvekar@ciphercloud.com>
Date2013-09-19 04:42 -0700
SubjectRe: subprocess call is not waiting.
Message-ID<6886842d-e89c-4ced-8502-fdaa250d1ac5@googlegroups.com>
subprocess.call(tempFileName, shell=True).communicate()

this process is not blocking. I want to make a blocking call to it. please help

[toc] | [next] | [standalone]


#54443

FromTerry Reedy <tjreedy@udel.edu>
Date2013-09-19 15:58 -0400
Message-ID<mailman.161.1379620749.18130.python-list@python.org>
In reply to#54420
On 9/19/2013 7:42 AM, harish.barvekar@gmail.com wrote:
> subprocess.call(tempFileName, shell=True).communicate()

should raise an AttributeError as the int returned by subprocess.call 
does not have a .communicate method.

> this process is not blocking.

Why do you think that? All function calls block until the function 
returns, at which point blocking ceases.  If you call 
Popen(someprog).communicate() and someprog runs quickly, you will hardly 
notice the blocking time.

-- 
Terry Jan Reedy

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web