fix: iteration node in parallel mode token count error (#11539)

Co-authored-by: Novice Lee <novicelee@NoviPro.local>
pull/12097/head
Novice 1 year ago committed by Joel
parent 14912b2a1d
commit 72b1bed79d

@ -182,7 +182,6 @@ class IterationNode(BaseNode[IterationNodeData]):
future.add_done_callback(thread_pool.task_done_callback)
futures.append(future)
succeeded_count = 0
empty_count = 0
while True:
try:
event = q.get(timeout=1)
@ -593,3 +592,4 @@ class IterationNode(BaseNode[IterationNodeData]):
parallel_mode_run_id=parallel_mode_run_id,
):
q.put(event)
graph_engine.graph_runtime_state.total_tokens += graph_engine_copy.graph_runtime_state.total_tokens

Loading…
Cancel
Save