[pypy-svn] r61609 - pypy/trunk/pypy/lib

arigo at codespeak.net arigo at codespeak.net
Sat Feb 7 16:34:30 CET 2009


Author: arigo
Date: Sat Feb  7 16:34:30 2009
New Revision: 61609

Modified:
   pypy/trunk/pypy/lib/_pypy_interact.py
Log:
Check in advance if readline can really be initialized.
Fixes test_i_flag_overrides_isatty in translator/goal/test/test_app_main.py.


Modified: pypy/trunk/pypy/lib/_pypy_interact.py
==============================================================================
--- pypy/trunk/pypy/lib/_pypy_interact.py	(original)
+++ pypy/trunk/pypy/lib/_pypy_interact.py	Sat Feb  7 16:34:30 2009
@@ -16,6 +16,9 @@
     except ImportError:
         pass
     try:
+        from pyrepl.simple_interact import check
+        if not check():
+            raise ImportError
         from pyrepl.simple_interact import run_multiline_interactive_console
     except ImportError:
         run_simple_interactive_console(mainmodule)



More information about the Pypy-commit mailing list