{"record":{"id":"ff593e274c9b665b","repo":"deepseek-ai/deepseek-harness","slug":"acp-connection-closed-with-an-error-string-err","errorCode":null,"errorMessage":"acp: connection closed with an error: ${String(error)}","messagePattern":"acp: connection closed with an error: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/acp/acp/src/index.ts","lineNumber":515,"sourceCode":"      }\n      if (failures.length > 0) {\n        // The production consumer logs this AggregateError through `String`,\n        // which renders only its message. Embed every per-session diagnostic,\n        // including nested causes and aggregate members, in that message.\n        const detail = failures.map(failure => errorChain(failure)).join('; ')\n        throw new AggregateError(\n          failures,\n          `ACP agent teardown failed for ${failures.length} session(s): ${detail}`,\n        )\n      }\n    })()\n    return quiescing\n  }\n\n  /* v8 ignore start -- production transport rejection and teardown failure. */\n  void conn.closed\n    .catch((error: unknown) => {\n      logger.warn(`acp: connection closed with an error: ${String(error)}`)\n    })\n    .then(quiesce)\n    .catch((error: unknown) => {\n      logger.warn(`acp: connection-close teardown failed: ${String(error)}`)\n    })\n  /* v8 ignore stop */\n\n  ctx.effect(() => quiesce, 'acp.connection')\n}\n\n/**\n * Build per-agent options from plugin config without assigning absent optional fields.\n * @param config - ACP provider/model configuration.\n * @returns the configured fields only.\n */\nfunction agentOptions(config: AcpConfig): { provider?: string; model?: string } {\n  return {\n    ...config.provider !== undefined ? { provider: config.provider } : {},","sourceCodeStart":497,"sourceCodeEnd":533,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/acp/acp/src/index.ts#L497-L533","documentation":"Error \"acp: connection closed with an error: ${String(error)}\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/acp/acp/src/index.ts:515 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the connection error in the log and re-establish the ACP connection."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b150a551b8d465e31e418e1b2eaf5e79bbb7d28e","analyzedAt":"2026-08-24T18:12:29.105Z","schemaVersion":2},"datasetVersion":"2026-08-24T22:17:12.610Z"}