mirror of
https://github.com/explosion/spaCy.git
synced 2025-01-13 18:56:36 +03:00
Don't terminate a process that isn't alive
This commit is contained in:
parent
a4fdec9005
commit
421b23ae5c
|
@ -385,8 +385,10 @@ def test_autoport(en_vocab):
|
|||
proc1.terminate()
|
||||
proc2.terminate()
|
||||
finally:
|
||||
proc1.terminate()
|
||||
proc2.terminate()
|
||||
if proc1.is_alive():
|
||||
proc1.terminate()
|
||||
if proc2.is_alive():
|
||||
proc2.terminate()
|
||||
time.sleep(2)
|
||||
proc1.close()
|
||||
proc2.close()
|
||||
|
|
Loading…
Reference in New Issue
Block a user