MCPcopy
hub / github.com/simstudioai/sim / queuedExecutor

Function queuedExecutor

apps/sim/lib/workspaces/fork/mapping/cascade.test.ts:13–21  ·  view source on GitHub ↗

Executor that returns the queued result arrays in the order queries are issued.

(results: unknown[][])

Source from the content-addressed store, hash-verified

11
12/** Executor that returns the queued result arrays in the order queries are issued. */
13function queuedExecutor(results: unknown[][]): DbOrTx {
14 let index = 0
15 const builder = {
16 from: () => builder,
17 innerJoin: () => builder,
18 where: () => Promise.resolve(results[index++] ?? []),
19 }
20 return { select: () => builder } as unknown as DbOrTx
21}
22
23function ref(kind: ForkReference['kind'], sourceId: string): ForkReference {
24 return { kind, sourceId, subBlockKey: 'tools', required: false }

Callers 1

cascade.test.tsFile · 0.85

Calls 1

resolveMethod · 0.65

Tested by

no test coverage detected