MCPcopy Index your code
hub / github.com/TanStack/ai / syntheticRunError

Function syntheticRunError

packages/ai-sandbox/src/run.ts:39–45  ·  view source on GitHub ↗

Build the synthetic RUN_ERROR chunk appended when the stream throws.

(message: string)

Source from the content-addressed store, hash-verified

37
38/** Build the synthetic RUN_ERROR chunk appended when the stream throws. */
39function syntheticRunError(message: string): StreamChunk {
40 const chunk: { type: EventType.RUN_ERROR; message: string } = {
41 type: EventType.RUN_ERROR,
42 message,
43 }
44 return chunk
45}
46
47export interface PipeToRunLogOptions {
48 log: RunEventLog

Callers 1

pipeToRunLogFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected