From 284885fecb4cf23a401643a5993105127b89a1ac Mon Sep 17 00:00:00 2001 From: Collin Dutter Date: Fri, 16 Aug 2024 10:59:51 -0700 Subject: [PATCH 1/2] Trigger build From 54583972e81c0a3d95f17aa5a01d75b3d3d08c1e Mon Sep 17 00:00:00 2001 From: Collin Dutter Date: Fri, 16 Aug 2024 10:57:41 -0700 Subject: [PATCH 2/2] Use subtask output if no action output --- CHANGELOG.md | 1 + griptape/tasks/toolkit_task.py | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e06aa4c6d..33ccbc3d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - `Workflow` threads not being properly cleaned up after completion. +- Crash when `ToolAction`s were missing output due to an `ActionsSubtask` exception. ## [0.29.1] - 2024-08-02 diff --git a/griptape/tasks/toolkit_task.py b/griptape/tasks/toolkit_task.py index 59d8f9f90..cb6058141 100644 --- a/griptape/tasks/toolkit_task.py +++ b/griptape/tasks/toolkit_task.py @@ -83,7 +83,12 @@ def prompt_stack(self) -> PromptStack: for action in s.actions ] action_results = [ - ToolAction(name=action.name, path=action.path, tag=action.tag, output=action.output) + ToolAction( + name=action.name, + path=action.path, + tag=action.tag, + output=action.output if action.output is not None else s.output, + ) for action in s.actions ]