MCPcopy Create free account
hub / github.com/vercel/vercel / killAll

Function killAll

packages/python/src/start-dev-server.ts:455–477  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

453 cleanupHandlersInstalled = true;
454
455 const killAll = () => {
456 for (const [key, info] of PERSISTENT_SERVERS.entries()) {
457 try {
458 process.kill(info.pid, 'SIGTERM');
459 } catch (err: any) {
460 debug(`Error sending SIGTERM to ${info.pid}: ${err}`);
461 }
462 try {
463 process.kill(info.pid, 'SIGKILL');
464 } catch (err: any) {
465 debug(`Error sending SIGKILL to ${info.pid}: ${err}`);
466 }
467 PERSISTENT_SERVERS.delete(key);
468 }
469 if (restoreWarnings) {
470 try {
471 restoreWarnings();
472 } catch (err: any) {
473 debug(`Error restoring warnings: ${err}`);
474 }
475 restoreWarnings = null;
476 }
477 };
478
479 // Do not exit on signals, so other interruption handlers
480 // can perform their cleanup routine.

Callers 1

Calls 3

debugFunction · 0.90
killMethod · 0.80
deleteMethod · 0.45

Tested by

no test coverage detected