()
| 722 | } |
| 723 | |
| 724 | async function processQueue() { |
| 725 | if (processing) return; |
| 726 | processing = true; |
| 727 | while (messageQueue.length > 0) { |
| 728 | const req = messageQueue.shift()!; |
| 729 | try { |
| 730 | await handleRequest(req); |
| 731 | } catch { |
| 732 | send({ jsonrpc: "2.0", id: null, error: { code: -32700, message: "Parse error" } }); |
| 733 | } |
| 734 | } |
| 735 | processing = false; |
| 736 | } |
| 737 | |
| 738 | process.stdin.setEncoding("utf-8"); |
| 739 | process.stdin.on("data", (chunk: string) => { |
no test coverage detected