Skip to content

Commit 782a24b

Browse files
Nov1c444Novice Lee
authored andcommitted
fix: remove the unused QueueWorkflowPartialSuccessEvent handle in workflow (#11669)
Co-authored-by: Novice Lee <[email protected]>
1 parent b96686c commit 782a24b

File tree

1 file changed

+0
-22
lines changed

1 file changed

+0
-22
lines changed

api/core/app/apps/workflow/generate_task_pipeline.py

-22
Original file line numberDiff line numberDiff line change
@@ -394,28 +394,6 @@ def _process_stream_response(
394394
# save workflow app log
395395
self._save_workflow_app_log(workflow_run)
396396

397-
yield self._workflow_finish_to_stream_response(
398-
task_id=self._application_generate_entity.task_id, workflow_run=workflow_run
399-
)
400-
elif isinstance(event, QueueWorkflowPartialSuccessEvent):
401-
if not workflow_run:
402-
raise Exception("Workflow run not initialized.")
403-
404-
if not graph_runtime_state:
405-
raise Exception("Graph runtime state not initialized.")
406-
workflow_run = self._handle_workflow_run_partial_success(
407-
workflow_run=workflow_run,
408-
start_at=graph_runtime_state.start_at,
409-
total_tokens=graph_runtime_state.total_tokens,
410-
total_steps=graph_runtime_state.node_run_steps,
411-
outputs=event.outputs,
412-
exceptions_count=event.exceptions_count,
413-
conversation_id=None,
414-
trace_manager=trace_manager,
415-
)
416-
# save workflow app log
417-
self._save_workflow_app_log(workflow_run)
418-
419397
yield self._workflow_finish_to_stream_response(
420398
task_id=self._application_generate_entity.task_id, workflow_run=workflow_run
421399
)

0 commit comments

Comments
 (0)