From b44842d1de238eed38114ae9d83b7d72d5861dd5 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Mon, 24 Feb 2025 13:17:19 +0000 Subject: [PATCH] fix: handle None arguments in tool usage comparison Co-Authored-By: Joe Moura --- src/crewai/tools/tool_usage.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/crewai/tools/tool_usage.py b/src/crewai/tools/tool_usage.py index 703baf76a..0d162b1f4 100644 --- a/src/crewai/tools/tool_usage.py +++ b/src/crewai/tools/tool_usage.py @@ -297,6 +297,8 @@ class ToolUsage: # For other tools, check all arguments return ( calling.tool_name == last_tool_usage.tool_name + and calling.arguments is not None + and last_tool_usage.arguments is not None and calling.arguments == last_tool_usage.arguments ) return False