https://github.com/python/cpython/commit/5aedee55b606207ea28d236c8fd460161f492e78
commit: 5aedee55b606207ea28d236c8fd460161f492e78
branch: 3.14
author: Miss Islington (bot) <[email protected]>
committer: zware <[email protected]>
date: 2026-09-22T02:49:16Z
summary:

[3.14] Disable inputrc in test_pyrepl basic REPL output test (GH-157937)

Specifically, `test_no_newline` would fail if the user's `~/.inputrc`
sets `editing-mode vi`, which adds `(ins)` for "insert mode" to the
beginning of the prompt.
(cherry picked from commit d5dede7442ebb4a05cff5309697fb5dcba3d5297)

Co-authored-by: Zachary Ware <[email protected]>

files:
M Lib/test/test_pyrepl/test_pyrepl.py

diff --git a/Lib/test/test_pyrepl/test_pyrepl.py 
b/Lib/test/test_pyrepl/test_pyrepl.py
index a10e908e513db90..9ea74971e2e89d7 100644
--- a/Lib/test/test_pyrepl/test_pyrepl.py
+++ b/Lib/test/test_pyrepl/test_pyrepl.py
@@ -1950,6 +1950,8 @@ def test_no_newline(self):
         env = os.environ.copy()
         env.pop("PYTHON_BASIC_REPL", "")
         env["PYTHON_BASIC_REPL"] = "1"
+        # Ensure user's .inputrc doesn't interfere with basic REPL output
+        env["INPUTRC"] = "/dev/null"
 
         commands = "print('Something pretty long', end='')\nexit()\n"
         expected_output_sequence = "Something pretty long>>> exit()"

_______________________________________________
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]

Reply via email to