File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
apps/sim/app/workspace/[workspaceId]/w/[workflowId]/hooks Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -1460,15 +1460,19 @@ export function useWorkflowExecution() {
14601460 return
14611461 }
14621462
1463- // For trigger blocks with no snapshot, create an empty one
1464- const effectiveSnapshot : SerializableExecutionState = snapshot || {
1463+ // For trigger blocks, always use empty snapshot to prevent stale data from different
1464+ // execution paths from being resolved. For non-trigger blocks, use the existing snapshot.
1465+ const emptySnapshot : SerializableExecutionState = {
14651466 blockStates : { } ,
14661467 executedBlocks : [ ] ,
14671468 blockLogs : [ ] ,
14681469 decisions : { router : { } , condition : { } } ,
14691470 completedLoops : [ ] ,
14701471 activeExecutionPath : [ ] ,
14711472 }
1473+ const effectiveSnapshot : SerializableExecutionState = isTriggerBlock
1474+ ? emptySnapshot
1475+ : snapshot || emptySnapshot
14721476
14731477 // Extract mock payload for trigger blocks
14741478 let workflowInput : any
You can’t perform that action at this time.
0 commit comments