• Victor Stinner's avatar
    Close #12363: fix a race condition in siginterrupt() tests · d6284963
    Victor Stinner yazdı
    The previous tests used time.sleep() to synchronize two processes. If the host
    was too slow, the test could fail.
    
    The new tests only use one process, but they use a subprocess to:
    
     - have only one thread
     - have a timeout on the blocking read (select cannot be used in the test,
       select always fail with EINTR, the kernel doesn't restart it)
     - not touch signal handling of the parent process
    d6284963
test_signal.py 27 KB