cpython/Lib/test/test_pyrepl
Miss Islington (bot) 6e9845455e
[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 c985822d86)

Co-authored-by: Victor Stinner <vstinner@python.org>
2025-10-07 19:38:12 +02:00
..
__init__.py [3.14] gh-138801: re-enable pyrepl tests on Windows (GH-138802) (GH-138815) 2025-09-15 16:42:36 +02:00
__main__.py
eio_test_script.py [3.14] gh-135329: prevent infinite traceback loop on Ctrl-C for strace (GH-138133) (#138973) 2025-09-16 11:04:49 +00:00
support.py gh-133346: Make theming support in _colorize extensible (GH-133347) 2025-05-05 23:45:25 +02:00
test_eventqueue.py [3.14] gh-135621: Remove dependency on curses from PyREPL (GH-136758) (GH-136915) 2025-07-21 13:02:41 +02:00
test_input.py
test_interact.py gh-131927: Prevent emitting optimizer warnings twice in the REPL (#131993) 2025-04-12 11:34:36 +01:00
test_keymap.py
test_pyrepl.py [3.14] gh-135621: Remove dependency on curses from PyREPL (GH-136758) (GH-136915) 2025-07-21 13:02:41 +02:00
test_reader.py [3.14] gh-136801: Fix PyREPL syntax highlightning on match cases after multi-line case (GH-136804) (GH-136813) 2025-07-19 15:56:40 +02:00
test_terminfo.py [3.14] gh-135621: Remove dependency on curses from PyREPL (GH-136758) (GH-136915) 2025-07-21 13:02:41 +02:00
test_unix_console.py [3.14] gh-135329: Use longer timeout in pyrepl test_repl_eio() (GH-139503) (#139506) 2025-10-07 19:38:12 +02:00
test_utils.py [3.14] gh-138318, PyREPL: builtins should not be highlighted when used as attribute names (GH-138319) (#138654) 2025-09-08 13:29:53 +00:00
test_windows_console.py [3.14] GH-130328: Fix WindowsConsoleGetEventTests after gh-133728 (gh-134660) (gh-134666) 2025-05-25 18:43:07 +00:00