We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 384062e commit 1fd99e3Copy full SHA for 1fd99e3
1 file changed
apps/sim/lib/workflows/executor/human-in-the-loop-manager.ts
@@ -64,8 +64,17 @@ function updateResumeOutputInAggregationBuffers(
64
if (!isRecord(scope) || !isRecord(scope.currentIterationOutputs)) continue
65
66
const outputs = scope.currentIterationOutputs
67
- if (outputs[stateBlockKey] !== undefined || outputs[pauseBlockId] !== undefined) {
68
- delete outputs[pauseBlockId]
+ const pausedEntry =
+ outputs[stateBlockKey] !== undefined
69
+ ? stateBlockKey
70
+ : outputs[pauseBlockId] !== undefined
71
+ ? pauseBlockId
72
+ : undefined
73
+
74
+ if (pausedEntry !== undefined && isPausedOutputForContext(outputs[pausedEntry], contextId)) {
75
+ if (pausedEntry !== stateBlockKey) {
76
+ delete outputs[pausedEntry]
77
+ }
78
outputs[stateBlockKey] = mergedOutput
79
}
80
0 commit comments