!37254 Ignore exceptions during python termination
Merge pull request !37254 from h.farahat/mp_ter
This commit is contained in:
commit
97c7d50da1
|
@ -2928,7 +2928,10 @@ class _PythonMultiprocessing(cde.PythonMultiprocessingRuntime):
|
|||
self.threads_to_workers = {}
|
||||
|
||||
def __del__(self):
|
||||
self.terminate()
|
||||
try:
|
||||
self.terminate()
|
||||
except TypeError:
|
||||
pass
|
||||
|
||||
# This wait function is for cleaning zombie subprocesses
|
||||
@staticmethod
|
||||
|
|
|
@ -341,7 +341,10 @@ class SamplerFn:
|
|||
thread.join()
|
||||
|
||||
def __del__(self):
|
||||
self._stop_subprocess()
|
||||
try:
|
||||
self._stop_subprocess()
|
||||
except TypeError:
|
||||
pass
|
||||
|
||||
|
||||
def _subprocess_handle(eof, signum, frame):
|
||||
|
|
Loading…
Reference in New Issue