Message8449
The raw_input function does not work properly at the REPL in Jython 2.7b2 on java1.8.0_05 on Windows 7 or 8. It appears to work in scripts.
When raw_input is issued in the REPL the prompt never appears and it is necessary to press CTRL/C or CTRL/Z to abort the read (which also aborts Jython). Everything works fine when reading using sys.stdin.readline(), the exact opposite of a problem in jython2.7b1 which I reported last year.
Examples:
C:\Users\emcdowell\progs\jython>java -jar jython.jar
Jython 2.7b2 (default:a5bc0032cf79+, Apr 22 2014, 21:20:17)
[Java HotSpot(TM) Client VM (Oracle Corporation)] on java1.8.0_05
>>> import sys
>>> line = sys.stdin.readline()
My input text.
>>> line
'My input text.\n'
>>> # Works!
>>> →
C:\Users\emcdowell\progs\jython>java -jar jython.jar
Jython 2.7b2 (default:a5bc0032cf79+, Apr 22 2014, 21:20:17)
[Java HotSpot(TM) Client VM (Oracle Corporation)] on java1.8.0_05
>>> line = raw_input('Prompt? ')
... My input text.
...
...
...
... →
C:\Users\emcdowell\progs\jython> |
|
Date |
User |
Action |
Args |
2014-05-20 18:37:41 | emcdowell | set | recipients:
+ emcdowell |
2014-05-20 18:37:41 | emcdowell | set | messageid: <1400611061.28.0.866945295253.issue2152@psf.upfronthosting.co.za> |
2014-05-20 18:37:41 | emcdowell | link | issue2152 messages |
2014-05-20 18:37:40 | emcdowell | create | |
|