summaryrefslogtreecommitdiffstats
path: root/Lib/subprocess.py
Commit message (Collapse)AuthorAgeFilesLines
* Merged revisions 82973 via svnmerge fromStefan Krah2010-07-191-0/+2
| | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/release27-maint ........ r82973 | stefan.krah | 2010-07-19 16:41:08 +0200 (Mon, 19 Jul 2010) | 4 lines Issue #9265: Incorrect name passed as arg[0] when shell=True and executable specified. ........
* Merged revisions 82075 via svnmerge fromJean-Paul Calderone2010-06-181-3/+3
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r82075 | jean-paul.calderone | 2010-06-18 16:00:17 -0400 (Fri, 18 Jun 2010) | 12 lines Revert r60115 This revision introduced quoting for strings containing | based on a misunderstanding of the commonly used quoting rules used on Windows. | is interpreted by cmd.exe, not by the MS C runtime argv initializer. It only needs to be quoted if it is part of an argument passed through cmd.exe. See issue1300, issue7839, and issue8972. ........
* Merged revisions 81179 via svnmerge fromVictor Stinner2010-05-141-3/+3
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r81179 | victor.stinner | 2010-05-14 23:52:26 +0200 (ven., 14 mai 2010) | 2 lines Fix regression introduced by r81154 (Issue #5099, subprocess destructor) ........
* Merged revisions 81154 via svnmerge fromBrett Cannon2010-05-141-16/+33
| | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r81154 | brett.cannon | 2010-05-13 17:21:48 -0700 (Thu, 13 May 2010) | 15 lines subprocess.Popen.__del__ referenced global objects, which is a no-no thanks to interpreter shutdown semantics. Same issue goes for the methods that __del__ called. Now all the methods capture the global objects it needs as default values to private parameters (could have stuck them on the class object itself, but since the objects have nothing directly to do with the class that seemed wrong). There is no test as making one that works is hard. This patch was verified against a consistently failing test in Mercurial's test suite, though, so it has been tested in some regard. Closes issue #5099. Thanks to Mary Stern for the bug report and Gabriel Genellina for writing another patch for the same issue and attempting to write a test. ........
* Merged revisions 80439 via svnmerge fromBrian Curtin2010-04-241-47/+39
| | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r80439 | brian.curtin | 2010-04-24 10:40:11 -0500 (Sat, 24 Apr 2010) | 6 lines Fix #7838. Add docstrings and privatize _subprocess implementation details. Since CREATE_NEW_* are used for the creation flags of a subprocess, they were added to __all__. The rest of the previously exposed attributes are now qualified by _subprocess.ATTR rather than importing *. ........
* Merged revisions ↵Georg Brandl2010-03-211-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 76538,76559,76882-76883,76886,76891-76892,76920,76924-76925,77081,77084,77086,77092 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r76538 | georg.brandl | 2009-11-26 21:48:25 +0100 (Do, 26 Nov 2009) | 1 line #7400: typo. ........ r76559 | georg.brandl | 2009-11-28 12:11:50 +0100 (Sa, 28 Nov 2009) | 1 line Fix versions and spacing. ........ r76882 | georg.brandl | 2009-12-19 18:30:28 +0100 (Sa, 19 Dez 2009) | 1 line #7527: use standard versionadded tags. ........ r76883 | georg.brandl | 2009-12-19 18:34:32 +0100 (Sa, 19 Dez 2009) | 1 line #7521: remove Py_GetBuildNumber(), which was removed in favor of Py_GetBuildInfo(). ........ r76886 | georg.brandl | 2009-12-19 18:43:33 +0100 (Sa, 19 Dez 2009) | 1 line #7493: review of Design FAQ by Florent Xicluna. ........ r76891 | georg.brandl | 2009-12-19 19:16:31 +0100 (Sa, 19 Dez 2009) | 1 line #7479: add note about function availability on Unices. ........ r76892 | georg.brandl | 2009-12-19 19:20:18 +0100 (Sa, 19 Dez 2009) | 1 line #7480: remove tautology. ........ r76920 | georg.brandl | 2009-12-20 15:20:16 +0100 (So, 20 Dez 2009) | 1 line #7495: backport Programming FAQ review to trunk. ........ r76924 | georg.brandl | 2009-12-20 15:28:05 +0100 (So, 20 Dez 2009) | 1 line Small indentation fix. ........ r76925 | georg.brandl | 2009-12-20 15:33:20 +0100 (So, 20 Dez 2009) | 1 line #7381: subprocess documentation and library docstring consistency fixes. ........ r77081 | georg.brandl | 2009-12-28 08:59:05 +0100 (Mo, 28 Dez 2009) | 1 line #7577: fix signature of PyBuffer_FillInfo(). ........ r77084 | georg.brandl | 2009-12-28 09:01:59 +0100 (Mo, 28 Dez 2009) | 1 line #7586: fix typo. ........ r77086 | georg.brandl | 2009-12-28 09:09:32 +0100 (Mo, 28 Dez 2009) | 1 line #7381: consistency update, and backport avoiding ``None >= 0`` check from py3k. ........ r77092 | georg.brandl | 2009-12-28 09:48:24 +0100 (Mo, 28 Dez 2009) | 1 line #7404: remove reference to non-existing example files. ........
* Merged revisions 78523 via svnmerge fromGregory P. Smith2010-03-011-3/+14
| | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r78523 | gregory.p.smith | 2010-02-28 16:05:08 -0800 (Sun, 28 Feb 2010) | 3 lines Issue #1068268: The subprocess module now handles EINTR in internal os.waitpid and os.read system calls where appropriate. ........
* Merged revisions 76168 via svnmerge fromEric Smith2009-11-091-1/+3
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r76168 | eric.smith | 2009-11-09 10:16:23 -0500 (Mon, 09 Nov 2009) | 1 line Issue 7294: Fixed URL in a comment. ........
* Merged revisions 75143 via svnmerge fromPhilip Jenvey2009-09-291-15/+41
| | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r75143 | philip.jenvey | 2009-09-29 12:10:15 -0700 (Tue, 29 Sep 2009) | 5 lines #5329: fix os.popen* regression from 2.5: don't execute commands as a sequence through the shell. also document the correct subprocess replacement for this case patch from Jean-Paul Calderone and Jani Hakala ........
* Issue #6274. Fixed a potential FD leak in subprocess.py.Facundo Batista2009-06-191-82/+90
|
* Merged revisions 70137 via svnmerge fromHirokazu Yamamoto2009-03-031-32/+15
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r70137 | hirokazu.yamamoto | 2009-03-04 07:18:14 +0900 | 1 line Issue #5179: Fixed subprocess handle leak on failure on windows. ........
* Merged revisions 69620 via svnmerge fromGeorg Brandl2009-02-141-0/+3
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r69620 | georg.brandl | 2009-02-14 18:01:36 +0100 (Sa, 14 Feb 2009) | 1 line #5179: don't leak PIPE fds when child execution fails. ........
* Remove warnings generated for the suprocess module when run under -3. RequiredBrett Cannon2008-08-081-7/+8
| | | | | | commenting out True/False compatbility stuff, remove a use of apply(), and remove a use of buffer() (just pulled the solution used in 3.0 which is direct slicing).
* - Issue #1857: subprocess.Popen.poll gained an additional _deadstate keywordGregory P. Smith2008-08-041-4/+8
| | | | | argument in python 2.5, this broke code that subclassed Popen to include its own poll method. Fixed my moving _deadstate to an _internal_poll method.
* - Issue #2113: Fix error in subprocess.Popen if the select system call isGregory P. Smith2008-07-061-1/+6
| | | | interrupted by a signal.
* Fixes issue2791: subprocess.Popen.communicate leaked a file descripton untilGregory P. Smith2008-05-261-0/+2
| | | | | | | the last reference to the Popen instance was dropped. Adding explicit close() calls fixes it. Candidate for backport to release25-maint.
* Added kill, terminate and send_signal to subprocess.PopenChristian Heimes2008-04-191-0/+32
| | | | The bits and pieces for the Windows side were already in place. The POSIX side is trivial (as usual) and uses os.kill().
* Fix issue 1300: Quote command line arguments that contain a '|' character inGregory P. Smith2008-01-191-3/+3
| | | | subprocess.list2cmdline (windows).
* Undo an unnecessary else: and indentation that r60104 added.Gregory P. Smith2008-01-191-58/+57
| | | | | | | | | | | | try: ... except: ... raise else: ... the else: is unecessary due to the blind except: with a raise.
* Fixes issue1336 - a race condition could occur when forking if the gcGregory P. Smith2008-01-191-58/+71
| | | | | | | kicked in during the critical section. solution: disable gc during that section. Patch contributed by jpa and updated by me to cover the race condition still existing what therve from twistedmatrix pointed out (already seen and fixed in twisted's own subprocess code).
* fix comment typos, use not arg instead of arg == "", add test coverageGregory P. Smith2008-01-191-3/+3
| | | | for inside of the final if needquotes: within subprocess.list2cmdline().
* #1663329: add os.closerange() to close a range of fds,Georg Brandl2008-01-191-7/+2
| | | | | ignoring errors, and use this in subprocess to speed up subprocess creation in close_fds mode. Patch by Mike Klaas.
* Applied patch 1669481, slightly modified: Support close_fds on Win32Peter Astrand2007-05-261-5/+4
|
* Remove trailing whitespace in docstringNeal Norwitz2007-05-111-2/+0
|
* Fix typo in docstring (the module is popen2, not 3).Neal Norwitz2007-05-111-1/+1
|
* Bug #1704790: bind name "sys" locally in __del__ method so that it isGeorg Brandl2007-04-211-1/+1
| | | | not cleared before __del__ is run.
* Whitespace normalization.Tim Peters2007-03-121-1/+1
|
* Applied patch 1124861.3.patch to solve bug #1124861: Automatically create ↵Peter Astrand2007-02-061-3/+25
| | | | pipes on Windows, if GetStdHandle fails. Will backport.
* We had several if statements checking the value of a fd. This is unsafe, ↵Peter Astrand2007-02-021-15/+15
| | | | since valid fds might be zero. We should check for not None instead.
* Whitespace normalization.Tim Peters2007-01-301-1/+1
|
* Fix for bug #1634343: allow specifying empty arguments on WindowsPeter Astrand2007-01-131-1/+1
|
* Avoid O(N**2) bottleneck in _communicate_(). Fixes #1598181.Peter Astrand2007-01-071-3/+4
|
* Re-implemented fix for #1531862 once again, in a way that works with Python ↵Peter Astrand2007-01-071-2/+6
| | | | 2.2. Fixes bug #1603424.
* SF bug #1623890, fix argument name in docstringNeal Norwitz2006-12-291-1/+1
|
* Bug #1357915: allow all sequence types for shell arguments inGeorg Brandl2006-10-291-0/+2
| | | | subprocess.
* Fixed subprocess bug #1531862 again, after removing testsGustavo Niemeyer2006-09-071-8/+4
| | | | offending buildbot
* Revert 51758 because it broke all the buildbotsNeal Norwitz2006-09-061-4/+8
|
* Fixing #1531862: Do not close standard file descriptors in theGustavo Niemeyer2006-09-061-8/+4
| | | | subprocess module.
* Guard for _active being None in __del__ method.Georg Brandl2006-07-201-1/+1
|
* Whitespace normalization.Tim Peters2006-07-181-1/+1
|
* Bug #1223937: CalledProcessError.errno -> CalledProcessError.returncode.Peter Astrand2006-07-141-8/+13
|
* Fix doco. Backport candidate.Neal Norwitz2006-07-101-1/+1
|
* Applied patch #1506758: Prevent MemoryErrors with large MAXFD.Peter Astrand2006-06-221-1/+1
|
* Bug #1500293: fix memory leaks in _subprocess module.Georg Brandl2006-06-041-5/+5
|
* Try to fix breakage caused by patch #1479181, r45850Neal Norwitz2006-05-021-2/+2
|
* Patch #1467770: Add Popen objects to _active only in __del__.Martin v. Löwis2006-04-101-10/+26
| | | | | | Introduce _child_active member to keep track on whether a child needs to be waited for. Backport candidate.
* Changed license header: Now simply referring to PSF. This closes bugPeter Astrand2005-09-231-22/+2
| | | | 1138653.
* Whitespace normalization.Tim Peters2005-03-281-4/+4
|
* Corrected bug in list2cmdline wrt backslashes. Fixes #1083306.Peter Astrand2005-03-031-0/+1
|
* Optimization for communicate(): If only one of stdin/stdout/stderr isPeter Astrand2005-03-031-16/+29
| | | | redirected, using select() or threads is unnecessary.