MCPcopy Index your code
hub / github.com/python/cpython / kill_python

Function kill_python

Lib/test/support/script_helper.py:220–229  ·  view source on GitHub ↗

Run the given Popen process until completion and return stdout.

(p)

Source from the content-addressed store, hash-verified

218
219
220def kill_python(p):
221 """Run the given Popen process until completion and return stdout."""
222 p.stdin.close()
223 data = p.stdout.read()
224 p.stdout.close()
225 # try to cleanup the child so we don't appear to leak when running
226 # with regrtest -R.
227 p.wait()
228 subprocess._cleanup()
229 return data
230
231
232def make_script(script_dir, script_basename, source, omit_suffix=False):

Calls 4

closeMethod · 0.45
readMethod · 0.45
waitMethod · 0.45
_cleanupMethod · 0.45

Used in the wild real call sites across dependent graphs

searching dependent graphs…