feat(pydantic-ai): Add tool description to execute_tool spans #5596
1 issue
code-review: Found 1 issue (1 medium)
Medium
Test asserts tool description is present when PR description says it should be omitted - `tests/integrations/pydantic_ai/test_pydantic_ai.py:2869-2871`
The test test_tool_without_description_omits_tool_description asserts that SPANDATA.GEN_AI_TOOL_DESCRIPTION in tool_span['data'] is True and its value is None. However, the PR description explicitly states: 'If no description is available (e.g. the tool has no docstring), the attribute is omitted from the span entirely.' The test docstring also says 'omits tool description' but the assertions verify the opposite - that it IS present with a None value.
Duration: 1m 7s · Tokens: 551.8k in / 6.8k out · Cost: $0.92 (+extraction: $0.00)
Annotations
Check warning on line 2871 in tests/integrations/pydantic_ai/test_pydantic_ai.py
github-actions / warden: code-review
Test asserts tool description is present when PR description says it should be omitted
The test `test_tool_without_description_omits_tool_description` asserts that `SPANDATA.GEN_AI_TOOL_DESCRIPTION in tool_span['data']` is True and its value is None. However, the PR description explicitly states: 'If no description is available (e.g. the tool has no docstring), the attribute is omitted from the span entirely.' The test docstring also says 'omits tool description' but the assertions verify the opposite - that it IS present with a None value.