[litellm-agent] Staging → litellm_internal_staging (5/14/2026) - #27895
[litellm-agent] Staging → litellm_internal_staging (5/14/2026)#27895oss-pr-review-agent-shin[bot] wants to merge 3 commits into
Conversation
Squash-merged by litellm-agent from oss-agent-shin's PR.
|
@greptile please review |
|
|
Greptile SummaryThis merge batch delivers two changes: a docstring addition to
Confidence Score: 5/5Safe to merge — both changes are narrowly scoped, well-tested with mock-only tests, and do not touch auth or critical request routing. The empty-text-block sanitizer is non-mutating, correctly implemented, and covered by six unit tests plus an integration-level regression test. The JSON model entry is consistent with the other regional profiles and is validated by a new config pin test. The docstring change is cosmetic. No files require special attention.
|
| Filename | Overview |
|---|---|
| litellm/_logging.py | Adds a one-line docstring to _disable_debugging() — cosmetic only, no functional change. |
| litellm/llms/anthropic/common_utils.py | Adds strip_empty_text_blocks_from_anthropic_messages and _is_empty_text_block helpers; logic is correct, non-mutating, and well-documented. |
| litellm/llms/anthropic/experimental_pass_through/messages/handler.py | Applies the new empty-text-block sanitizer at the entry point of anthropic_messages() before any backend dispatch, mirroring the guard already in the /v1/chat/completions path. |
| model_prices_and_context_window.json | Adds jp.anthropic.claude-sonnet-4-6 entry matching the capability and pricing of the existing au./eu. regional profiles; intentionally omits cache_creation_input_token_cost_above_1hr which only us. carries. |
| tests/test_litellm/llms/anthropic/test_anthropic_common_utils.py | Adds six pure unit tests for strip_empty_text_blocks_from_anthropic_messages, covering the core regression scenario, whitespace/null/missing text, non-mutation, and block-type preservation. |
| tests/test_litellm/llms/anthropic/experimental_pass_through/messages/test_anthropic_experimental_pass_through_messages_handler.py | Adds a regression test verifying that anthropic_messages() forwards sanitized messages to the backend handler; uses mocks only, no real network calls. |
| tests/test_litellm/test_claude_sonnet_4_6_config.py | New test file that pins the expected set of Bedrock region-prefixed claude-sonnet-4-6 entries and validates that jp. pricing matches au.; reads local JSON, no network calls. |
Reviews (3): Last reviewed commit: "Sanitize empty text content blocks on /v..." | Re-trigger Greptile
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
…27831) Squash-merged by litellm-agent from Cyberfilo's PR.
|
@greptile please review |
Squash-merged by litellm-agent from Cyberfilo's PR.
|
@greptile please review |
Merged PRs (2)
Auto-updated by litellm-agent on each merge.