MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / _quiesce

Function _quiesce

scripts/test-impact/coverage_live_v2.py:348–363  ·  view source on GitHub ↗
(proc)

Source from the content-addressed store, hash-verified

346
347
348def _quiesce(proc):
349 sent = []
350 for sig in (signal.SIGTERM, signal.SIGKILL):
351 if proc.poll() is not None and not _group_exists(proc.pid):
352 return True, sent
353 try:
354 os.killpg(proc.pid, sig)
355 sent.append(signal.Signals(sig).name)
356 except ProcessLookupError:
357 pass
358 until = time.monotonic() + GRACE
359 while time.monotonic() < until:
360 if proc.poll() is not None and not _group_exists(proc.pid):
361 return True, sent
362 time.sleep(0.02)
363 return proc.poll() is not None and not _group_exists(proc.pid), sent
364
365
366def _run(evidence, label, argv, environment, timeout, cwd, watch_raw=False):

Callers 1

_runFunction · 0.85

Calls 2

_group_existsFunction · 0.85
pollMethod · 0.45

Tested by

no test coverage detected