Agent Mesh
Go a2aa2a-protocolagent-meshagentic-aiinferencemcpmeshmesh-networknetwork-securitynetworking-aip2p-network
fix(examples): guard gemini-buddy stdin against EPIPE crash
Tomas Tormof539d142fc0c
diff --git a/development/examples/gemini-buddy-mcp/buddy_server.mjs b/development/examples/gemini-buddy-mcp/buddy_server.mjsindex b55a5878..138538cf 100644--- a/development/examples/gemini-buddy-mcp/buddy_server.mjs+++ b/development/examples/gemini-buddy-mcp/buddy_server.mjs@@ -37,6 +37,7 @@ function runGemini(text) {child.stdout.on("data", (d) => { stdout += d; });child.stderr.on("data", (d) => { stderr += d; });child.on("error", reject);+ child.stdin.on("error", reject); // fail the request instead of crashing on EPIPEchild.on("close", (exitCode) => {if (exitCode === 0) resolve(stdout.trim());else reject(new Error(stderr.trim() || `gemini exited with code ${exitCode}`));