wrap_tool_call() — langchain Function Reference
Architecture documentation for the wrap_tool_call() function in test_sync_async_wrappers.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 2a7a396d_560d_b909_7682_09221ed97fc7["wrap_tool_call()"] a63452cc_7237_9847_c5e9_9f223812d05a["SyncOnlyMiddleware"] 2a7a396d_560d_b909_7682_09221ed97fc7 -->|defined in| a63452cc_7237_9847_c5e9_9f223812d05a b32ae1d3_dc67_5e65_9233_c87c7775379d["wrap_tool_call()"] b32ae1d3_dc67_5e65_9233_c87c7775379d -->|calls| 2a7a396d_560d_b909_7682_09221ed97fc7 20b56989_a6d2_b59b_34e9_720ef7799e73["test_mixed_middleware_composition_async_path_fails_with_sync_only()"] 20b56989_a6d2_b59b_34e9_720ef7799e73 -->|calls| 2a7a396d_560d_b909_7682_09221ed97fc7 764efc16_2be8_1972_2479_1920fef42a5a["test_mixed_middleware_composition_sync_path_with_async_only_fails()"] 764efc16_2be8_1972_2479_1920fef42a5a -->|calls| 2a7a396d_560d_b909_7682_09221ed97fc7 b32ae1d3_dc67_5e65_9233_c87c7775379d["wrap_tool_call()"] 2a7a396d_560d_b909_7682_09221ed97fc7 -->|calls| b32ae1d3_dc67_5e65_9233_c87c7775379d style 2a7a396d_560d_b909_7682_09221ed97fc7 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/langchain_v1/tests/unit_tests/agents/middleware/core/test_sync_async_wrappers.py lines 43–49
def wrap_tool_call(
self,
request: ToolCallRequest,
handler: Callable[[ToolCallRequest], ToolMessage | Command[Any]],
) -> ToolMessage | Command[Any]:
call_log.append("sync_called")
return handler(request)
Domain
Subdomains
Calls
Called By
Source
Frequently Asked Questions
What does wrap_tool_call() do?
wrap_tool_call() is a function in the langchain codebase, defined in libs/langchain_v1/tests/unit_tests/agents/middleware/core/test_sync_async_wrappers.py.
Where is wrap_tool_call() defined?
wrap_tool_call() is defined in libs/langchain_v1/tests/unit_tests/agents/middleware/core/test_sync_async_wrappers.py at line 43.
What does wrap_tool_call() call?
wrap_tool_call() calls 1 function(s): wrap_tool_call.
What calls wrap_tool_call()?
wrap_tool_call() is called by 3 function(s): test_mixed_middleware_composition_async_path_fails_with_sync_only, test_mixed_middleware_composition_sync_path_with_async_only_fails, wrap_tool_call.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free