summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2013-02-04 14:47:39 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2013-02-04 14:47:39 (GMT)
commitb3f194d10951d5c23af885c6d55c45dfb0db0666 (patch)
treeaa40c095d34ff160840f755604fb389f88487940 /Doc
parent0b4591e0eb80b78b4c6a4aa6a4071c74c253bde7 (diff)
downloadcpython-b3f194d10951d5c23af885c6d55c45dfb0db0666.zip
cpython-b3f194d10951d5c23af885c6d55c45dfb0db0666.tar.gz
cpython-b3f194d10951d5c23af885c6d55c45dfb0db0666.tar.bz2
Issue #16903: Popen.communicate() on Unix now accepts strings when
universal_newlines is true as on Windows.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/subprocess.rst7
1 files changed, 4 insertions, 3 deletions
diff --git a/Doc/library/subprocess.rst b/Doc/library/subprocess.rst
index fc456a1..b4adc02 100644
--- a/Doc/library/subprocess.rst
+++ b/Doc/library/subprocess.rst
@@ -537,9 +537,10 @@ Instances of the :class:`Popen` class have the following methods:
.. method:: Popen.communicate(input=None)
Interact with process: Send data to stdin. Read data from stdout and stderr,
- until end-of-file is reached. Wait for process to terminate. The optional
- *input* argument should be a byte string to be sent to the child process, or
- ``None``, if no data should be sent to the child.
+ until end-of-file is reached. Wait for process to terminate. The optional
+ *input* argument should be data to be sent to the child process, or
+ ``None``, if no data should be sent to the child. The type of *input*
+ must be bytes or, if *universal_newlines* was ``True``, a string.
:meth:`communicate` returns a tuple ``(stdoutdata, stderrdata)``.