Skip to content

Commit 767b951

Browse files
committed
Docs: Clarify that input is one time only on communicate()
1 parent de856d9 commit 767b951

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Doc/library/subprocess.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -831,7 +831,9 @@ Instances of the :class:`Popen` class have the following methods:
831831

832832
If the process does not terminate after *timeout* seconds, a
833833
:exc:`TimeoutExpired` exception will be raised. Catching this exception and
834-
retrying communication will not lose any output.
834+
retrying communication will not lose any output. Supplying *input* to a
835+
subsequent post-timeout :meth:`communicate` call is in undefined behavior
836+
and may become an error in the future.
835837

836838
The child process is not killed if the timeout expires, so in order to
837839
cleanup properly a well-behaved application should kill the child process and

0 commit comments

Comments
 (0)