{"record":{"id":"20d15a25eea8ae45","repo":"paperclipai/paperclip","slug":"tool-timeout","errorCode":"tool_timeout","errorMessage":"Remote MCP tool call timed out","messagePattern":"Remote MCP tool call timed out","errorType":"http","errorClass":"ToolGatewayHttpError","httpStatus":504,"severity":"error","filePath":"server/src/services/tool-gateway.ts","lineNumber":6140,"sourceCode":"      }\n      if (error instanceof ToolGatewayHttpError) {\n        throw new ToolGatewayHttpError(\n          error.status,\n          error.message,\n          error.reasonCode,\n          {\n            ...error.details,\n            execution: error.details.execution ?? execution,\n          },\n        );\n      }\n      if (error instanceof Error && error.name === \"AbortError\") {\n        await markRemoteConnectionHealth(\n          connection,\n          \"error\",\n          \"Remote MCP tool call timed out.\",\n        );\n        throw new ToolGatewayHttpError(\n          504,\n          \"Remote MCP tool call timed out\",\n          \"tool_timeout\",\n          {\n            connectionId: connection.id,\n            catalogEntryId: entry.id,\n            execution,\n          },\n        );\n      }\n      await markRemoteConnectionHealth(\n        connection,\n        \"error\",\n        \"Remote MCP tool call failed.\",\n      );\n      throw new ToolGatewayHttpError(\n        502,\n        \"Remote MCP tool call failed\",","sourceCodeStart":6122,"sourceCodeEnd":6158,"githubUrl":"https://github.com/paperclipai/paperclip/blob/3f1d897a7c018d76563a21c6e39c3c9b03933622/server/src/services/tool-gateway.ts#L6122-L6158","documentation":"The remote MCP tools/call fetch aborted via AbortError, meaning the upstream server exceeded the configured timeout. Connection health is marked error and a 504/gateway-timeout style failure is returned; the call itself may or may not have executed remotely, so blind retry of non-idempotent tools is unsafe.","triggerScenarios":"Thrown at server/src/services/tool-gateway.ts:3159 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["The remote MCP call timed out. Retry, increase the timeout if configurable, or check the remote server's latency/load."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3f1d897a7c018d76563a21c6e39c3c9b03933622","analyzedAt":"2026-09-18T08:03:59.046Z","contentChangedAt":"2026-09-18T08:03:59.046Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}