]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[3.14] gh-135329: Use longer timeout in pyrepl test_repl_eio() (GH-139503) (#139506)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 7 Oct 2025 17:38:12 +0000 (19:38 +0200)
committerGitHub <noreply@github.com>
Tue, 7 Oct 2025 17:38:12 +0000 (19:38 +0200)
commit6e9845455e0c49792b26732dfadb1e1c5aab8bea
treee6b9347c5024879977b3a61e8bae76d2a4d9614a
parent9e13cc28962ce92ea080cb7988d95fff70955d96
[3.14] gh-135329: Use longer timeout in pyrepl test_repl_eio() (GH-139503) (#139506)

gh-135329: Use longer timeout in pyrepl test_repl_eio() (GH-139503)

Replace hardcoded 5 seconds with support.SHORT_TIMEOUT.

Fix the following error on slow CI such as GitHub Action UBSan:

test test_pyrepl failed -- Traceback (most recent call last):
  File "Lib/test/test_pyrepl/test_unix_console.py", line 362, in test_repl_eio
    _, err = proc.communicate(timeout=5)  # sleep for pty to settle
             ~~~~~~~~~~~~~~~~^^^^^^^^^^^
  File "Lib/subprocess.py", line 1219, in communicate
    stdout, stderr = self._communicate(input, endtime, timeout)
                     ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
  File "Lib/subprocess.py", line 2126, in _communicate
    self._check_timeout(endtime, orig_timeout, stdout, stderr)
    ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "Lib/subprocess.py", line 1266, in _check_timeout
    raise TimeoutExpired(
    ...<2 lines>...
            stderr=b''.join(stderr_seq) if stderr_seq else None)
subprocess.TimeoutExpired: Command '[...]' timed out after 5 seconds
(cherry picked from commit c985822d86892cd0a978e6e63945be3c0e59217c)

Co-authored-by: Victor Stinner <vstinner@python.org>
Lib/test/test_pyrepl/test_unix_console.py