It can be done with termios under Unix, but not under Windows.
I do it easily in perl with TERM::Readkey, or in Windows Batch files.
If an answer has been given here, I have been unable to find it.
I find it hard to believe that python omits such a basic operation available in essentially all other languages.