Python program stopping execution wating for keypress
Erno Kuusela
erno-news at erno.iki.fi
Wed Feb 21 14:21:00 EST 2001
In article <dFOk6.857$t21.9975 at news3.oke.nextra.no>, "Syver Enstad"
<syver at NOSPAMcyberwatcher.com> writes:
| Some times the programs just stop in the middle of the execution,
| essentially sleeping as they use no processor time. The times I've
| observed this is on applications running in a console, so I tried
| pressing a key and then the application starts executing again.
some piece of code you are using probably is buggy and tries
to read from stdin. try booby-trapping it by assigning a non-file
object to sys.stdin (or doing sys.stdin.close()).
-- erno
More information about the Python-list
mailing list