MCPcopy Create free account
hub / github.com/Zoo-Code-Org/Zoo-Code / pull

Function pull

apps/vscode-e2e/src/suite/providers/xai.test.ts:167–175  ·  view source on GitHub ↗
(controller)

Source from the content-addressed store, hash-verified

165
166 const stream = new ReadableStream<Uint8Array>({
167 pull(controller) {
168 if (index < events.length) {
169 controller.enqueue(encoder.encode(`data: ${JSON.stringify(events[index++])}\n\n`))
170 return
171 }
172
173 controller.enqueue(encoder.encode("data: [DONE]\n\n"))
174 controller.close()
175 },
176 })
177
178 return new Response(stream, {

Callers

nothing calls this directly

Calls 2

enqueueMethod · 0.80
closeMethod · 0.65

Tested by

no test coverage detected