We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0077368 commit c32d426Copy full SHA for c32d426
src/google/adk/code_executors/tool_code_generator.py
@@ -266,10 +266,9 @@ def {tool.name}({param_str}) -> dict:
266
"""
267
kwargs = {{k: v for k, v in locals().items() if v is not None}}
268
response = _call_adk_tool("{tool.name}", **kwargs)
269
- # Extract the result from the tool server response
270
- if isinstance(response, dict) and "result" in response:
271
- return response["result"]
272
- return response
+ # On success, the response is a dict with a "result" key.
+ # On failure, _call_adk_tool raises an exception.
+ return response["result"]
273
274
'''
275
return stub
0 commit comments