@@ -55,7 +55,7 @@ compatibility with older versions, see the :ref:`call-function-trio` section.
55
55
If *capture_output * is true, stdout and stderr will be captured.
56
56
When used, the internal :class: `Popen ` object is automatically created with
57
57
``stdout=PIPE `` and ``stderr=PIPE ``. The *stdout * and *stderr * arguments may
58
- not be used as well .
58
+ not be supplied at the same time as * capture_output * .
59
59
60
60
The *timeout * argument is passed to :meth: `Popen.communicate `. If the timeout
61
61
expires, the child process will be killed and waited for. The
@@ -1002,14 +1002,14 @@ calls these functions.
1002
1002
Run the command described by *args *. Wait for command to complete, then
1003
1003
return the :attr: `~Popen.returncode ` attribute.
1004
1004
1005
- This is equivalent to: :
1005
+ Code needing to capture stdout or stderr should use :func: ` run ` instead :
1006
1006
1007
1007
run(...).returncode
1008
1008
1009
- (except that the * input * and * check * parameters are not supported)
1009
+ To suppress stdout or stderr, supply a value of :data: ` DEVNULL `.
1010
1010
1011
- The arguments shown above are merely the most
1012
- common ones. The full function signature is largely the
1011
+ The arguments shown above are merely some common ones.
1012
+ The full function signature is the
1013
1013
same as that of the :class: `Popen ` constructor - this function passes all
1014
1014
supplied arguments other than *timeout * directly through to that interface.
1015
1015
@@ -1030,14 +1030,14 @@ calls these functions.
1030
1030
:exc: `CalledProcessError ` object will have the return code in the
1031
1031
:attr: `~CalledProcessError.returncode ` attribute.
1032
1032
1033
- This is equivalent to: :
1033
+ Code needing to capture stdout or stderr should use :func: ` run ` instead :
1034
1034
1035
1035
run(..., check=True)
1036
1036
1037
- (except that the * input * parameter is not supported)
1037
+ To suppress stdout or stderr, supply a value of :data: ` DEVNULL `.
1038
1038
1039
- The arguments shown above are merely the most
1040
- common ones. The full function signature is largely the
1039
+ The arguments shown above are merely some common ones.
1040
+ The full function signature is the
1041
1041
same as that of the :class: `Popen ` constructor - this function passes all
1042
1042
supplied arguments other than *timeout * directly through to that interface.
1043
1043
@@ -1067,7 +1067,7 @@ calls these functions.
1067
1067
1068
1068
run(..., check=True, stdout=PIPE).stdout
1069
1069
1070
- The arguments shown above are merely the most common ones.
1070
+ The arguments shown above are merely some common ones.
1071
1071
The full function signature is largely the same as that of :func: `run ` -
1072
1072
most arguments are passed directly through to that interface.
1073
1073
However, explicitly passing ``input=None `` to inherit the parent's
@@ -1077,8 +1077,9 @@ calls these functions.
1077
1077
encoding of the output data may depend on the command being invoked, so the
1078
1078
decoding to text will often need to be handled at the application level.
1079
1079
1080
- This behaviour may be overridden by setting *universal_newlines * to
1081
- ``True `` as described above in :ref: `frequently-used-arguments `.
1080
+ This behaviour may be overridden by setting *text *, *encoding *, *errors *,
1081
+ or *universal_newlines * to ``True `` as described in
1082
+ :ref: `frequently-used-arguments ` and :func: `run `.
1082
1083
1083
1084
To also capture standard error in the result, use
1084
1085
``stderr=subprocess.STDOUT ``::
0 commit comments