mirror of
https://github.com/tiennm99/litellm.git
synced 2026-07-29 12:20:24 +00:00
The empty-line filter in __next__/__anext__ called .strip() without checking the type first. When the Responses API yields Pydantic BaseModel events (e.g. ResponseCreatedEvent), this raises AttributeError. Add an isinstance(str_line, str) guard so non-string objects pass through to _handle_string_chunk as intended. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Testing for litellm/
This directory 1:1 maps the the litellm/ directory, and can only contain mocked tests.
The point of this is to:
- Increase test coverage of
litellm/ - Make it easy for contributors to add tests for the
litellm/package and easily run tests without needing LLM API keys.
File name conventions
litellm/proxy/test_caching_routes.pymaps tolitellm/proxy/caching_routes.pytest_<filename>.pymaps tolitellm/<filename>.py