I tried to read one char from the console in PyCharm (without pressing the enter key), but to no avail. The msvcrt.getch() functions stop the code, but do not respond to keystrokes (even input), and msvcrt.kbhit() always returns 0. For example, this code does not print anything:
import msvcrt while 1: if msvcrt.kbhit(): print 'reading' print 'done'
I am using Windows 7, PyCharm 3.4 (the same standby heppens).
What's wrong? Is there any other way to just read input without input?
pycharm msvcrt getch kbhit
user4953886
source share