File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
apps/sim/app/workspace/[workspaceId]/w/components/preview Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -39,8 +39,8 @@ interface WorkflowStackEntry {
3939
4040/**
4141 * Extracts child trace spans from a workflow block's execution data.
42- * Checks both the `children` property (where trace span processing moves them)
43- * and the legacy `output.childTraceSpans` for compatibility .
42+ * Checks `children` property (where trace-spans processing puts them),
43+ * with fallback to `output.childTraceSpans` for old stored logs .
4444 */
4545function extractChildTraceSpans ( blockExecution : BlockExecutionData | undefined ) : TraceSpan [ ] {
4646 if ( ! blockExecution ) return [ ]
@@ -49,6 +49,7 @@ function extractChildTraceSpans(blockExecution: BlockExecutionData | undefined):
4949 return blockExecution . children
5050 }
5151
52+ // Backward compat: old stored logs may have childTraceSpans in output
5253 if ( blockExecution . output && typeof blockExecution . output === 'object' ) {
5354 const output = blockExecution . output as Record < string , unknown >
5455 if ( Array . isArray ( output . childTraceSpans ) ) {
You can’t perform that action at this time.
0 commit comments