MCPcopy Index your code
hub / github.com/simstudioai/sim / stripSpanCosts

Function stripSpanCosts

apps/sim/lib/logs/execution/trace-store.ts:62–70  ·  view source on GitHub ↗
(spans: unknown)

Source from the content-addressed store, hash-verified

60 * has consumed span costs in memory.
61 */
62export function stripSpanCosts(spans: unknown): void {
63 if (!Array.isArray(spans)) return
64 for (const span of spans) {
65 if (!span || typeof span !== 'object') continue
66 const record = span as { cost?: unknown; children?: unknown }
67 if ('cost' in record) record.cost = undefined
68 if (Array.isArray(record.children)) stripSpanCosts(record.children)
69 }
70}
71
72/**
73 * Externalizes heavy `execution_data` to object storage as a single large value

Callers 2

backfillTraceStorageFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected