https://github.com/python/cpython/commit/62729d79206014886f5de2b62a5824436e18b66f commit: 62729d79206014886f5de2b62a5824436e18b66f branch: 3.13 author: Miss Islington (bot) <[email protected]> committer: gpshead <[email protected]> date: 2024-12-30T21:15:44Z summary:
[3.13] gh-128342: Specify timeout unit in subprocess docstrings (GH-128343) (#128365) gh-128342: Specify timeout unit in subprocess docstrings (GH-128343) Specify timeout unit (seconds) in subprocess docstrings (cherry picked from commit dafe7a44630aa32bb411cceb45c7b7df725e3fe3) Co-authored-by: n-l-i <[email protected]> Co-authored-by: Terry Jan Reedy <[email protected]> files: M Lib/subprocess.py diff --git a/Lib/subprocess.py b/Lib/subprocess.py index b2dcb1454c139e..f614c903c8837c 100644 --- a/Lib/subprocess.py +++ b/Lib/subprocess.py @@ -386,7 +386,7 @@ def _text_encoding(): def call(*popenargs, timeout=None, **kwargs): """Run command with arguments. Wait for command to complete or - timeout, then return the returncode attribute. + for timeout seconds, then return the returncode attribute. The arguments are the same as for the Popen constructor. Example: @@ -523,8 +523,8 @@ def run(*popenargs, in the returncode attribute, and output & stderr attributes if those streams were captured. - If timeout is given, and the process takes too long, a TimeoutExpired - exception will be raised. + If timeout (seconds) is given and the process takes too long, + a TimeoutExpired exception will be raised. There is an optional argument "input", allowing you to pass bytes or a string to the subprocess's stdin. If you use this argument _______________________________________________ Python-checkins mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-checkins.python.org/ Member address: [email protected]
