MCPcopy Create free account
hub / github.com/Kilo-Org/cloud / terminate

Function terminate

services/cloud-agent-next/wrapper/src/utils.ts:212–221  ·  view source on GitHub ↗
(reason: TerminationReason)

Source from the content-addressed store, hash-verified

210 settled = true;
211 clearTimers();
212 removeAbortHandler();
213 if (destroyOpenPipes) destroyPipes();
214 const boundedStderr = appendBoundedTail(
215 stderr,
216 `${stderr.endsWith('\n') || stderr.length === 0 ? '' : '\n'}${terminationMessage(reason)}`,
217 maxOutputBytes
218 );
219 resolve({
220 stdout,
221 stderr: boundedStderr.value,
222 exitCode: EXEC_TIMEOUT_EXIT_CODE,
223 elapsedMs: Date.now() - startedAt,
224 terminationReason: reason,

Callers 3

abortHandlerFunction · 0.85
resetInactivityTimerFunction · 0.85
runProcessFunction · 0.85

Calls 3

killProcessFunction · 0.85
resolveTerminationFunction · 0.85
clearTimersFunction · 0.70

Tested by

no test coverage detected