Skip to content

Commit f7711af

Browse files
fix: handle omit type in _remove_not_given() for litellm model (#1893)
Co-authored-by: Kazuhiro Sera <seratch@openai.com>
1 parent 33f3401 commit f7711af

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/agents/extensions/models/litellm_model.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -500,7 +500,7 @@ def _fix_tool_message_ordering(
500500
return fixed_messages
501501

502502
def _remove_not_given(self, value: Any) -> Any:
503-
if isinstance(value, NotGiven):
503+
if value is omit or isinstance(value, NotGiven):
504504
return None
505505
return value
506506

0 commit comments

Comments
 (0)