MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / request

Function request

scripts/agent-eval/repro-daemon-clients.mjs:62–68  ·  view source on GitHub ↗
(method, params, rpcId, timeoutMs)

Source from the content-addressed store, hash-verified

60 });
61 const send = (obj) => child.stdin.write(JSON.stringify(obj) + '\n');
62 const request = (method, params, rpcId, timeoutMs) =>
63 new Promise((res) => {
64 let timer;
65 if (timeoutMs) timer = setTimeout(() => { waiters.delete(rpcId); res({ __timeout: true }); }, timeoutMs);
66 waiters.set(rpcId, (m) => { if (timer) clearTimeout(timer); res(m); });
67 send({ jsonrpc: '2.0', id: rpcId, method, params });
68 });
69 return { id, child, send, request };
70}
71

Callers

nothing calls this directly

Calls 4

resFunction · 0.85
sendFunction · 0.70
deleteMethod · 0.65
setMethod · 0.45

Tested by

no test coverage detected