Skip to content

The agent engineering platform.

community[patch]: compatibility with SQLAlchemy 1.4.x (#17954)

David Lovingd068e8ea5406
diff --git a/libs/community/langchain_community/tools/sql_database/tool.py b/libs/community/langchain_community/tools/sql_database/tool.py
index e68923bdcf..9d4f90b724 100644
--- a/libs/community/langchain_community/tools/sql_database/tool.py
+++ b/libs/community/langchain_community/tools/sql_database/tool.py
@@ -44,7 +44,7 @@ class QuerySQLDataBaseTool(BaseSQLDatabaseTool, BaseTool):
self,
query: str,
run_manager: Optional[CallbackManagerForToolRun] = None,
- ) -> Union[str, Sequence[Dict[str, Any]], Result[Any]]:
+ ) -> Union[str, Sequence[Dict[str, Any]], Result]:
"""Execute the query, return the results or an error message."""
return self.db.run_no_throw(query)