MCPcopy Create free account
hub / github.com/ActiveState/code / close

Method close

recipes/Python/578488_Threaded/recipe-578488.py:182–192  ·  view source on GitHub ↗
(self, timeout=None)

Source from the content-addressed store, hash-verified

180 )
181
182 def close(self, timeout=None):
183 with self._lock:
184 if not hasattr(self, '_process'):
185 return
186 try:
187 self._communicator.close(timeout)
188 finally:
189 if self._process.poll() is None:
190 self._process.kill()
191 del self._process
192 del self._communicator
193
194# I use the part above as a generic utility module. A simple echo example follows:
195

Callers 1

__del__Method · 0.95

Calls 3

closeMethod · 0.45
pollMethod · 0.45
killMethod · 0.45

Tested by

no test coverage detected