summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorGregory P. Smith <greg@mad-scientist.com>2008-12-05 02:27:01 (GMT)
committerGregory P. Smith <greg@mad-scientist.com>2008-12-05 02:27:01 (GMT)
commit26576801a683fba28e66fca4759fdc327e87ea3e (patch)
tree22e40cbdb3610f03c9c809ebc969c175ed0fd70b /Doc/library
parent1743201364feaa9ab56acda3ccef051b2dd1d814 (diff)
downloadcpython-26576801a683fba28e66fca4759fdc327e87ea3e.zip
cpython-26576801a683fba28e66fca4759fdc327e87ea3e.tar.gz
cpython-26576801a683fba28e66fca4759fdc327e87ea3e.tar.bz2
rename the new check_call_output to check_output. its less ugly.
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/subprocess.rst6
1 files changed, 3 insertions, 3 deletions
diff --git a/Doc/library/subprocess.rst b/Doc/library/subprocess.rst
index ae2f73b..96b7443 100644
--- a/Doc/library/subprocess.rst
+++ b/Doc/library/subprocess.rst
@@ -149,7 +149,7 @@ This module also defines two shortcut functions:
.. versionadded:: 2.5
-.. function:: check_call_output(*popenargs, **kwargs)
+.. function:: check_output(*popenargs, **kwargs)
Run command with arguments and return its output as a byte string.
@@ -159,13 +159,13 @@ This module also defines two shortcut functions:
The arguments are the same as for the Popen constructor. Example:
- >>> subprocess.check_call_output(["ls", "-l", "/dev/null"])
+ >>> subprocess.check_output(["ls", "-l", "/dev/null"])
'crw-rw-rw- 1 root root 1, 3 Oct 18 2007 /dev/null\n'
The stdout argument is not allowed as it is used internally.
To capture standard error in the result, use stderr=subprocess.STDOUT.
- >>> subprocess.check_call_output(
+ >>> subprocess.check_output(
["/bin/sh", "-c", "ls non_existant_file ; exit 0"],
stderr=subprocess.STDOUT)
'ls: non_existant_file: No such file or directory\n'