What is the correct way to read sys.stdin in iPython qtconsole
问题 I'm trying to write a library that will work as well across platforms as standard Python, iPython and within qtConsole. Everything works except my keyboard interaction. I want things like 'press any key' or 'press Y/N/Esc' In Windows this is easy with msvcrt and kbhit. (though I've not tried qtconsole in windows) In Linux this works using stdin and termios under both Python and iPython. The trouble is it seems qtconsole uses non-blocking stdin and does not support termios. You would think