MCPcopy Index your code
hub / github.com/anomalyco/opencode / invalidate

Function invalidate

packages/opencode/src/plugin/openai/ws.ts:165–171  ·  view source on GitHub ↗
(error: ProviderError.ResponseStreamError)

Source from the content-addressed store, hash-verified

163 }
164
165 function invalidate(error: ProviderError.ResponseStreamError) {
166 if (completed) return
167 completed = true
168 cleanup()
169 options.onConnectionInvalid?.(error)
170 controller?.error(error)
171 }
172
173 function resetIdleTimeout(message: string) {
174 if (completed) return

Callers 6

resetIdleTimeoutFunction · 0.70
onMessageFunction · 0.70
onErrorFunction · 0.70
onCloseFunction · 0.70
attachFunction · 0.70
config.tsFile · 0.50

Calls 1

cleanupFunction · 0.70

Tested by

no test coverage detected