From a84d5ded8280101fc0f874ff195513fcbd625256 Mon Sep 17 00:00:00 2001 From: Dominik Schweigl Date: Thu, 11 Sep 2025 07:55:53 +0000 Subject: [PATCH] fix: fix infinite loop in workflow tool with duplicate task names --- src/strands_tools/workflow.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/strands_tools/workflow.py b/src/strands_tools/workflow.py index b8726d13..25a5b54a 100644 --- a/src/strands_tools/workflow.py +++ b/src/strands_tools/workflow.py @@ -686,6 +686,9 @@ def start_workflow(self, workflow_id: str) -> Dict: completed_count = sum(1 for result in workflow["task_results"].values() if result["status"] == "completed") success_rate = (completed_count / total_tasks) * 100 if total_tasks > 0 else 0 + # Reinstantiate Task Executor for next workflow execution + self.task_executor = TaskExecutor() + return { "status": "success", "content": [