Commit graph

54803 commits

Author SHA1 Message Date
yuneng-jiang
93f52b591e
Merge pull request #50217 from BerriAI/litellm_backport_team_passthrough_skip_lts_1108
fix(passthrough): skip team deployments when picking proxy-wide pass-through credentials on lts/1.108.x
2026-11-05 10:18:24 -08:00
devin-ai-integration[bot]
798025d2cd chore: nudge the pull request head after a dropped sync
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 16:20:53 +00:00
devin-ai-integration[bot]
689494ad5f test(passthrough): type the team deployment helper and mark test locals Final 2026-11-05 16:09:04 +00:00
devin-ai-integration[bot]
78f53a1a5e fix(passthrough): skip team deployments when picking proxy-wide pass-through credentials on lts/1.108.x 2026-11-05 16:02:13 +00:00
Kerry Lu
d0bf0b0284
Merge pull request #50136 from BerriAI/litellm_backport_1108_picks_lts_1_108_x
fix(backport): backport 21 main fixes plus 2 prerequisites to lts/1.108.x for v1.108.1
2026-11-04 17:52:25 -08:00
kerry
d07d295ad5 bump: version 1.108.1
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 01:39:40 +00:00
kerry
d9c692b0c5 chore: bump litellm-enterprise 0.1.79 -> 0.1.79.post1
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 01:39:40 +00:00
Kerry Lu
9f0484b987 fix(openai): send chat completions through client.post so the SDK's per-message param transform stops holding the event loop (#46967)
* fix(openai): send chat completions through client.post so the SDK's per-message param transform stops holding the event loop

create() walks every message, content part and tool of the request through
openai._utils._transform before posting, 91 ms at 300k tokens and ~300 ms at
1M tokens on the event loop, and returns the same dict for the plain dicts
litellm builds. client.post is what create() calls after that walk, same
request, headers, retries, raw response and stream objects, so the chat
helpers now call it directly through the helper embeddings already used

* fix(openai): type the chat client.post result as LegacyAPIResponse so the type gate sees .headers and .parse

* fix(openai): assert the chat client.post result is a LegacyAPIResponse instead of casting it

* test(openai): stub client.post with a LegacyAPIResponse spec in the empty-response and no-leak tests

* test(core-utils): stub client.post with a LegacyAPIResponse spec in the agentic loop leak test

* test: every client.post stub on the OpenAI chat path returns a LegacyAPIResponse-spec'd mock

---------

Co-authored-by: devin-ai-integration[bot] <158243242+devin-ai-integration[bot]@users.noreply.github.com>
(cherry picked from commit e8550c1454)
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 01:39:40 +00:00
paveln83
d089d524a3 fix(caching): key cached async clients by a per-loop token instead of id(loop) (#48877)
* fix(caching): key cached async clients by a per-loop token instead of id(loop)

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* fix(caching): drop deferred closes queued on a collected event loop

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

* test(caching): pin that a close queued on a live loop waits for that loop

* test(caching): run loop-reuse tests until a loop address repeats

The collected-loop tests ran a fixed 50 loops and passed with the fix reverted whenever no loop reused an earlier address. They now stop at the first reuse and skip if none happens, through a shared helper.

* test(caching): cover the cache key fallback for loops without weak references

Also corrects the evicted client closer docstring: a dropped bucket's clients are left to the garbage collector.

* fix(http): free short-lived event loops whose handler finalizer close finished as the loop stopped

* fix(caching): share sync clients across event loops and catch a failed finalizer close

* fix(agentops): stop closing the shared sync http client after the auth call

---------

Co-authored-by: mateo <mateo@berri.ai>
Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Co-authored-by: mateo-berri <277851410+mateo-berri@users.noreply.github.com>
(cherry picked from commit 4ce724e3df)
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 01:39:40 +00:00
Kerry Lu
79a3567b66 feat(videos): serve custom_provider_map BaseVideoConfig providers on /v1/videos (#49785)
Backport of #49785 to lts/1.108.x.
Cherry-picked from fcef9cd0a3 (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 01:39:40 +00:00
Kerry Lu
f559536757 fix(logging): bill each SDK call its own native Bedrock guardrail trace when calls share one metadata dict (LIT-10239) (#48923)
Backport of #48923 to lts/1.108.x.
Cherry-picked from e21de0e418 (main).
2026-11-05 01:39:40 +00:00
Kerry Lu
a2e7cdcf7c feat(bedrock): price native guardrailConfig trace usage into spend and x-litellm-response-cost (#48278)
Backport of #48278 to lts/1.108.x.
Cherry-picked from 0b66a27528 (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 01:39:40 +00:00
devin-ai-integration[bot]
8fa525c90d fix(vertex-ai): sync tier prices and retirement floors (#49964)
Backport of #49964 to lts/1.108.x.
Cherry-picked from 62f85afacf (main). The cost-map schema keys and the schema test were re-applied by hand onto the line's test_utils.py, and the priority-markup test the line does not have was left out.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:26:44 +00:00
Kerry Lu
4f6bc3c507 fix(proxy): cancel the Admin UI's raw spend-log reads in Postgres after 30s (#49965)
Backport of #49965 to lts/1.108.x.
Cherry-picked from 2d0c720425 (main). The line keeps its inline session page query, so that read and the grouped count go through _query_spend_logs directly and _SpendLogsReader is not ported.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:26:44 +00:00
Kerry Lu
30c7420c4e fix(cost): bill gemini audio input and cached audio at flex, priority and batch rates (#48086)
Backport of #48086 to lts/1.108.x.
Cherry-picked from dc0237ccd7 (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:26:44 +00:00
Kerry Lu
de425fb956 fix(watsonx): read pass-through credentials from use_in_pass_through deployments (#49462)
Backport of #49462 to lts/1.108.x.
Cherry-picked from 948445c828 (main). get_proxy_wide_deployment_credentials hand-ported onto the line's _resolve_matching_deployment_api_key, since the line has no _get_deployment_credentials.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:26:44 +00:00
Kerry Lu
7dffccccae fix(batches): cost an unmanaged gs:// batch through the deployment that created it (#49301)
Backport of #49301 to lts/1.108.x.
Cherry-picked from 298911d61b (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:26:44 +00:00
Kerry Lu
277ee2e943 fix(proxy): abort the request with a 499 when the client disconnects during the body upload (#48640)
Backport of #48640 to lts/1.108.x.
Cherry-picked from 59b8c73930 (main). Dropped the pick's edit to the ValidationError branch the line does not have.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:26:44 +00:00
Kerry Lu
bc4c89bfc3 fix(proxy): cancel /team/spend/by_user in Postgres after 30s (#49922)
Backport of #49922 to lts/1.108.x.
Cherry-picked from 391c8013c9 (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:26:43 +00:00
Kerry Lu
6becdf304e fix(proxy): buffer tool discoveries in Redis and write LiteLLM_ToolTable in one statement per drain, on its own lock (#48089)
Backport of #48089 to lts/1.108.x.
Cherry-picked from e6a32bbeeb (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:15:40 +00:00
Kerry Lu
4bb0c86b2d test(router): set string fallback targets after Router init in the sdk cooldown cases (#48954)
Backport of #48954 to lts/1.108.x.
Cherry-picked from e4932a4539 (main).
2026-11-05 00:15:40 +00:00
Kerry Lu
8304f16942 fix(router): reject string fallback targets at Router init (LIT-10238) (#48943)
Backport of #48943 to lts/1.108.x.
Cherry-picked from 96fe78f96e (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:15:40 +00:00
Kerry Lu
825a555b5b fix(router): cool down failing deployments when fallbacks use string targets (LIT-10238) (#48913)
Backport of #48913 to lts/1.108.x.
Cherry-picked from 84c4c5aa5c (main).

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:15:40 +00:00
Kerry Lu
3a5abcfe1c fix(router): keep a lone deployment warm under router allowed_fails unless the policy names the exception (#48644)
Backport of #48644 to lts/1.108.x.
Cherry-picked from 8f31c7171d (main). Dropped the pick's edit to a stream-stall test the line does not have.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-11-05 00:15:40 +00:00
Rick
3df724803f fix(logging): drop a first-token time left over from a previous attempt (#47541)
Backport of #47541 to lts/1.108.x.
Cherry-picked from ced995df6e (main).
2026-11-05 00:15:40 +00:00
Kerry Lu
90bdf7fd01 fix(aiohttp_transport): keep the owned session open while a response stream is still being read (LIT-10237) (#48920)
Backport of #48920 to lts/1.108.x.
Cherry-picked from 4a70d80aef (main).
2026-11-05 00:15:40 +00:00
Kerry Lu
987819afd1 fix(anthropic): count search results and reject unsupported token-count blocks (#48699)
Backport of #48699 to lts/1.108.x.
Cherry-picked from 7acdf9f00d (main).
2026-11-05 00:15:40 +00:00
Ambuj Upadhyay
e7cb9a6483 fix(streaming): dict-usage arm drops prompt_tokens_details/completion_tokens_details its sibling arms preserve (#36678)
Backport of #36678 to lts/1.108.x.
Cherry-picked from cb70bc560e (main).
2026-11-05 00:15:40 +00:00
Kerry Lu
5b73742e4e fix(aiohttp_transport): close an owned aiohttp session when its transport is collected (#48650)
Backport of #48650 to lts/1.108.x.
Cherry-picked from d6edd37810 (main).
2026-11-05 00:15:40 +00:00
Kerry Lu
4695ad1deb fix(bedrock): price claude_platform calls from their own cost map rows (#48150)
Backport of #48150 to lts/1.108.x.
Cherry-picked from 560372456e (main).
2026-11-05 00:15:39 +00:00
yuneng-jiang
ba5b54f50c
Merge pull request #50091 from BerriAI/litellm_test_26a1e4
test: fix stale unit tests on 1.108 LTS
2026-11-04 13:34:43 -08:00
Yuneng Jiang
bbc8484790
test(utils): stop the register_model replay test leaking gpt-4o pricing on 1.108
Brings over the test_utils.py isolation fix from #47135. The replay test registered openai/gpt-4o with supports_function_calling false into the shared cost map, so a later function calling test on the same worker failed depending on xdist ordering
2026-11-04 12:23:06 -08:00
Yuneng Jiang
0b5b41ca1b
test(bedrock): let GovCloud lag on native structured output on 1.108
Brings over the test-only GovCloud exemption from #46870. The 1.108 cost map already mirrors main, where us-gov Sonnet 5 profiles mark supports_bedrock_native_structured_output false while the commercial base marks it true
2026-11-04 12:04:41 -08:00
Yuneng Jiang
003192d5df
test(proxy): drop stale team cache update test on 1.108
main removed test_team_cache_update_called in #35643. The 1.108 line already carries the auth cache freshness backport, so update_cache no longer reads the team cache and the test fails
2026-11-04 12:01:20 -08:00
yuneng-jiang
c3738cd97c
Merge pull request #50088 from BerriAI/litellm_ci_a09684
ci: run the OSV scan and unit tests on stable, rc and lts branches (#50086) [backport lts/1.108.x]
2026-11-04 11:56:54 -08:00
Yuneng Jiang
6bd64070a7
ci: run the OSV scan and unit tests on stable, rc and lts branches (#50086) 2026-11-04 11:42:40 -08:00
yuneng-jiang
b48077ff9e
Merge pull request #49985 from BerriAI/litellm_chore_3471bc
Some checks failed
LiteLLM Rust / rust-lint (push) Has been cancelled
LiteLLM Rust / rust-test (push) Has been cancelled
LiteLLM Rust / rust-wheel (push) Has been cancelled
chore(deps): align 1.108 dependency versions with main
2026-11-03 17:14:03 -08:00
Yuneng Jiang
2c5177b924
chore(deps): carry main's grype ignore for filelock onto 1.108 2026-11-03 17:11:22 -08:00
Yuneng Jiang
da398ed319
chore: update Next.js build artifacts (2026-11-04 01:05 UTC, node v24.19.0) 2026-11-03 17:05:08 -08:00
Yuneng Jiang
9f2570e0d1
chore(deps): align 1.108 dependency versions with main
Moves the Python, dashboard and vscode-extension dependencies flagged by OSV to the versions main locks, and carries over main's OSV ignore entries. diskcache keeps a renewed ignore because the disk cache backend removal (#48114) is not on this line
2026-11-03 17:03:56 -08:00
yuneng-jiang
49a2e97f84
Merge pull request #49962 from BerriAI/litellm_rc108_move_e2e_to_integration
test(e2e): repair rc/1.108.0 release qualification
2026-11-03 15:35:41 -08:00
Yuneng Jiang
573c0f6659
test(e2e): backport owned A2A integration coverage to rc 108 2026-11-03 14:38:59 -08:00
Yuneng Jiang
c86300491f
test(integration): use rc 108 database read helper 2026-11-03 14:27:15 -08:00
Yuneng Jiang
b5049a43ce
test(integration): backport Presidio Sail and Weave migrations to rc 108 2026-11-03 14:23:50 -08:00
yuneng-jiang
a7acb82a39
Merge pull request #49944 from BerriAI/litellm_e2e_qualification_rc108
test(e2e): backport qualification repairs to rc/1.108.0
2026-11-03 13:41:25 -08:00
Yuneng Jiang
e02e279d6a
test(e2e): backport qualification repairs to rc 1.108.0 2026-11-03 13:35:26 -08:00
yuneng-jiang
2881bacd68
Merge pull request #49723 from BerriAI/litellm_backport_49717_rc108
Some checks are pending
LiteLLM Rust / rust-lint (push) Waiting to run
LiteLLM Rust / rust-test (push) Waiting to run
LiteLLM Rust / rust-wheel (push) Waiting to run
fix(proxy): backport rc/1.108.0 integration repairs
2026-11-02 18:05:23 -08:00
Yuneng Jiang
d1b3f10c6f
test(integration): compare long-input bursts with matched benign traffic 2026-11-02 17:29:26 -08:00
Yuneng Jiang
de19b8d7ce
test(integration): await completed callbacks and observe locks directly
(cherry picked from commit 85e698a1ec)
2026-11-02 16:46:39 -08:00
Yuneng Jiang
ddb384ff61
test(integration): require deployment IDs on cache-hit failures
(cherry picked from commit f6498c364c)
2026-11-02 14:16:00 -08:00