From 2e4d7b15d7aa31132ae9eaa2afc8bba48c1d68ed Mon Sep 17 00:00:00 2001 From: David Wilson Date: Sat, 26 Jan 2019 20:16:28 +0000 Subject: [PATCH] parent: don't kill child when profiling=True --- mitogen/parent.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mitogen/parent.py b/mitogen/parent.py index 7b79155e..97917cae 100644 --- a/mitogen/parent.py +++ b/mitogen/parent.py @@ -1123,6 +1123,10 @@ class Stream(mitogen.core.Stream): LOG.debug('%r: immediate child is detached, won\'t reap it', self) return + if self.profiling: + LOG.info('%r: wont kill child because profiling=True', self) + return + if self._reaped: # on_disconnect() may be invoked more than once, for example, if # there is still a pending message to be sent after the first