fix(harness): wrap all async-only tools for sync clients (#2935)

This commit is contained in:
AochenShen99
2026-05-19 22:11:46 +08:00
committed by GitHub
parent c810e9f809
commit 3599b570a9
5 changed files with 260 additions and 6 deletions
@@ -205,7 +205,7 @@ def get_available_tools(
# Deduplicate by tool name — config-loaded tools take priority, followed by
# built-ins, MCP tools, and ACP tools. Duplicate names cause the LLM to
# receive ambiguous or concatenated function schemas (issue #1803).
all_tools = loaded_tools + builtin_tools + mcp_tools + acp_tools
all_tools = [_ensure_sync_invocable_tool(t) for t in loaded_tools + builtin_tools + mcp_tools + acp_tools]
seen_names: set[str] = set()
unique_tools: list[BaseTool] = []
for t in all_tools: