mirror of
https://github.com/usestrix/strix.git
synced 2026-08-28 05:25:00 +00:00
fix(executor): include error type in httpx RequestError messages
The str() of httpx.RequestError was often empty, making error messages unhelpful. Now includes the exception type (e.g., ConnectError) for better debugging.
This commit is contained in:
parent
d351b14ae7
commit
4de4be683f
1 changed files with 2 additions and 1 deletions
|
|
@ -89,7 +89,8 @@ async def _execute_tool_in_sandbox(tool_name: str, agent_state: Any, **kwargs: A
|
|||
raise RuntimeError("Authentication failed: Invalid or missing sandbox token") from e
|
||||
raise RuntimeError(f"HTTP error calling tool server: {e.response.status_code}") from e
|
||||
except httpx.RequestError as e:
|
||||
raise RuntimeError(f"Request error calling tool server: {e}") from e
|
||||
error_type = type(e).__name__
|
||||
raise RuntimeError(f"Request error calling tool server: {error_type}") from e
|
||||
|
||||
|
||||
async def _execute_tool_locally(tool_name: str, agent_state: Any | None, **kwargs: Any) -> Any:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue