MCPcopy Index your code
hub / github.com/codeaashu/claude-code / isStaleConnectionError

Function isStaleConnectionError

src/services/api/withRetry.ts:112–118  ·  view source on GitHub ↗
(error: unknown)

Source from the content-addressed store, hash-verified

110}
111
112function isStaleConnectionError(error: unknown): boolean {
113 if (!(error instanceof APIConnectionError)) {
114 return false
115 }
116 const details = extractConnectionErrorDetails(error)
117 return details?.code === 'ECONNRESET' || details?.code === 'EPIPE'
118}
119
120export interface RetryContext {
121 maxTokensOverride?: number

Callers 1

withRetryFunction · 0.85

Calls 1

Tested by

no test coverage detected