Python-2.7: No SIGINT possible in while loop with locks -


i implemented while loop locks in python-2.7 (see example) handle 2 lists loaded values other thread each. code works, not handle sigint (ctrl-c) anymore. example:

while true:   lock1:     if 0 < len(data_buf1):       foo(data_buf1.pop(0))   lock2:     if 0 < len(data_buf2):       bar(data_buf2.pop(0) 

what enable keyboard commands again?

update loop runs in main python process.


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

configurationsection - activeMq-5.13.3 setup configurations for wildfly 10.0.0 -