Commit graph

35652 commits

Author SHA1 Message Date
awais qureshi
a7b8e95415 fix(fireworks): skip #transform=inline for base64 data URLs
Closes #23583
2026-03-18 16:48:56 +05:00
awais qureshi
09884d84c0 fix(mcp): align token_url suppression with has_client_credentials property
Use oauth2_flow=client_credentials as the sole signal for 2LO suppression
instead of client_id+client_secret presence, matching MCPServer.has_client_credentials.

- Fixes P0: 3LO servers with client_id+client_secret now keep discovered
  token_url so exchange_token_with_server() can complete the auth-code exchange
- Fixes P1: _is_client_credentials_flow now mirrors has_client_credentials —
  both require explicit oauth2_flow opt-in, not field presence
- Fixes P1: 2LO integration test now sets oauth2_flow=client_credentials so
  has_client_credentials assertion passes
- Updates 3LO test to assert token_url IS populated from discovery and that
  authorization_url/scopes also survive
2026-03-18 16:25:43 +05:00
awais qureshi
e70ad1b980 fix(mcp): align token_url suppression with warning condition; use patch.object in all tests 2026-03-18 12:36:59 +05:00
awais qureshi
5346202689 test(mcp): use unittest.mock.patch.object instead of monkey-patching _descovery_metadata 2026-03-18 12:36:59 +05:00
awais qureshi
41cfceea38 test(mcp): add 2LO integration test for explicit token_url with client credentials 2026-03-18 12:36:59 +05:00
awais qureshi
3b3a244c1a Fix: Add a log warning when we suppress auto-discovery so existing users know what happened. 2026-03-18 12:36:59 +05:00
awais qureshi
942cdfbb85 fix(mcp): prevent auto-discovered token_url from triggering 2LO client_credentials grant. 2026-03-18 12:36:59 +05:00
awais qureshi
e50bfa5727 fix(mcp): prevent auto-discovered token_url from triggering 2LO client_credentials grant. 2026-03-18 12:36:59 +05:00
awais qureshi
f1ce68d38c fix(mcp): prevent auto-discovered token_url from triggering 2LO client_credentials grant. 2026-03-18 12:36:47 +05:00
Krish Dholakia
cec3e9e7d4
Merge pull request #23808 from voidborne-d/fix/shared-aiohttp-session-auto-recovery
fix: auto-recover shared aiohttp session when closed
2026-03-17 22:23:01 -07:00
yuneng-jiang
cfeafbe388
Merge pull request #23921 from BerriAI/litellm_mar17_extras
[Infra] Security and Proxy Extras for Nightly

Only known flaky tests failing. The fix for security and proxy extras worked
2026-03-17 18:01:19 -07:00
Krish Dholakia
5e570b3a66
Merge pull request #23911 from kelvin-tran/fix/cache-control-params-anthropic-document-file-message-blocks 2026-03-17 18:00:05 -07:00
Krish Dholakia
3bd4422a97
Merge pull request #23881 from xianzongxie-stripe/xianzong-upstream-changes 2026-03-17 17:58:36 -07:00
d 🔹
88f59e1465 fix: use AsyncMock for concurrent test consistency
Address review feedback from greptile — use new_callable=AsyncMock
on the concurrent test's patch.object to ensure the mock is properly
typed as async, even though side_effect already handles the coroutine.
2026-03-18 00:54:23 +00:00
Ishaan Jaffer
bae2eddd73 docs fix sidebar 2026-03-17 17:50:58 -07:00
Ishaan Jaff
fc315ab4af
docs(mcp_zero_trust): add MCP zero trust auth guide (#23918)
* docs(mcp_zero_trust): add MCP zero trust auth guide with hero image

* fix(docs): move hero image to static/img/ for Docusaurus build
2026-03-17 17:45:16 -07:00
yuneng-jiang
62835ff03d adding package-lock 2026-03-17 17:44:01 -07:00
yuneng-jiang
3e2845181c bumping next version 2026-03-17 17:38:09 -07:00
yuneng-jiang
cc37bf5934 adding build 2026-03-17 17:37:25 -07:00
yuneng-jiang
9fa1809c30 bump: version 0.4.56 → 0.4.57 2026-03-17 17:37:04 -07:00
yuneng-jiang
ac0de1d6a2
Merge pull request #23919 from BerriAI/mar17_ver_bump
[Infra] bump: version 1.82.3 → 1.82.4
2026-03-17 17:33:21 -07:00
yuneng-jiang
709581c5f9 bump: version 1.82.3 → 1.82.4 2026-03-17 17:31:45 -07:00
yuneng-jiang
195c0ee54d
Merge pull request #23917 from BerriAI/litellm_/loving-noyce
[Fix] Add contents:write permission to ghcr_deploy release job
2026-03-17 17:27:36 -07:00
yuneng-jiang
b8ffbba352 [Fix] Add contents:write permission to release job in ghcr_deploy workflow
The release job was failing with "Resource not accessible by integration"
because other jobs explicitly set permissions, causing GitHub to scope the
default token down for all jobs. The release job needs contents:write to
create GitHub releases.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 17:23:39 -07:00
Kelvin Tran
c6e9a2a40f
Merge branch 'main' into fix/cache-control-params-anthropic-document-file-message-blocks 2026-03-17 15:34:00 -07:00
Kelvin Tran
d0c5f494a8 fix: cache_control directive dropped anthropic document/file blocks 2026-03-17 14:30:12 -07:00
voidborne-d
ca8f5cffa0 style: apply black formatting to fix CI lint check 2026-03-17 18:52:57 +00:00
Xianzong Xie
cb88836486 Add incomplete response error propagation test
Committed-By-Agent: codex
Co-authored-by: codex <noreply@openai.com>
2026-03-17 11:39:12 -07:00
Xianzong Xie
bd5c39c4d1 Log incomplete details in background streaming
Committed-By-Agent: codex
Co-authored-by: codex <noreply@openai.com>
2026-03-17 11:35:50 -07:00
Xianzong Xie
3ff4ac3de3 Capture incomplete terminal error in background streaming
Committed-By-Agent: codex
Co-authored-by: codex <noreply@openai.com>
2026-03-17 11:21:26 -07:00
d 🔹
ef22144854 address P2 feedback: add lock docstring warning, remove redundant mock write
- Add WARNING docstring to _get_shared_session_lock() about not resetting
  the lock to None while coroutines may be in the recovery path
- Remove redundant proxy_server_module.shared_aiohttp_session assignment
  in mock_init (add_shared_session_to_data overwrites it synchronously)
2026-03-17 18:07:15 +00:00
ryan-crabbe
ef9cc33ee3
Merge pull request #23822 from BerriAI/litellm_ryan_march_16
Litellm ryan's daily branch march 16
2026-03-17 10:03:01 -07:00
yuneng-jiang
a622a1fa35
Merge pull request #23827 from BerriAI/litellm_internal_dev_03_16_2026
[Infra] Merge daily dev branch with main
2026-03-17 09:58:06 -07:00
yuneng-jiang
b4c9c8a9f0
Merge pull request #23868 from BerriAI/revert-22188-litellm_langfuse_key_leakage
Revert "fix: langfuse trace leak key on model params"
2026-03-17 08:58:30 -07:00
yuneng-jiang
467706ea30
Revert "fix: langfuse trace leak key on model params" 2026-03-17 08:58:07 -07:00
d
32ecd24116 fix: address P2 review feedback - exception handling and warning accuracy
- Add try/except around _initialize_shared_aiohttp_session call to catch
  and log exceptions (instead of letting them bubble to outer handler)
- Fix warning message when re-checked session is None (was incorrectly
  logging closed session ID on a None session)
- Add debug logging to outer except handler instead of bare pass
- Add test for _initialize_shared_aiohttp_session raising exception
2026-03-17 13:09:26 +00:00
d 🔹
9e09bbc1df fix: reset _shared_session_lock in all tests for event loop isolation
Address Greptile P1 review: tests that exercise the closed-session code
path need to reset the module-level lock to avoid RuntimeError on
Python < 3.10 when asyncio.Lock is reused across different event loops.
2026-03-17 09:54:01 +00:00
voidborne-d
ab4fda2eeb fix: add asyncio.Lock to prevent session/connector leak on concurrent recreation
When multiple requests detect a closed shared session simultaneously,
they would each create a new aiohttp.ClientSession, leaking intermediate
sessions and their TCP connectors. Added double-checked locking pattern
with asyncio.Lock to ensure only one coroutine recreates the session.

Added concurrent recreation test case.
2026-03-17 08:08:44 +00:00
yuneng-jiang
dcbaa0512b
Merge pull request #23826 from BerriAI/litellm_yj_march_16_2026
[Infra] Merge personal dev branch with daily dev branch
2026-03-16 23:47:50 -07:00
yuneng-jiang
ad62071fd3
Merge pull request #22188 from BerriAI/litellm_langfuse_key_leakage
fix: langfuse trace leak key on model params
2026-03-16 23:46:06 -07:00
Ryan Crabbe
302292c805 Merge remote-tracking branch 'origin/main' into litellm_ryan_march_16 2026-03-16 22:51:45 -07:00
ryan-crabbe
cde28aa018
Merge pull request #23819 from BerriAI/litellm_fix-csv-export
fix(ui): CSV export empty on Global Usage page
2026-03-16 22:46:36 -07:00
yuneng-jiang
a087c44c95
Merge pull request #23812 from BerriAI/litellm_disable_custom_api_keys
[Feature] Disable Custom Virtual Key Values via UI Setting
2026-03-16 22:37:48 -07:00
Ryan Crabbe
c098eca509 fix(ui): CSV export empty on Global Usage page
Aggregated endpoint returns empty breakdown.entities; fall back to
grouping breakdown.api_keys by team_id.
2026-03-16 22:36:23 -07:00
yuneng-jiang
471e0f147e [Fix] Remove "API" from custom key description text
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 22:35:44 -07:00
yuneng-jiang
0b0fe7e263 [Fix] Rename toggle label to "Disable custom Virtual key values"
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 22:26:53 -07:00
Krish Dholakia
245a3d2b26
Revert "docs: add v1.82.3 release notes and update provider_endpoints_support…" (#23817)
This reverts commit 966124966f.
2026-03-16 22:26:45 -07:00
yuneng-jiang
c687e631b4 [Feature] Add disable_custom_api_keys toggle to UI Settings page
Adds a toggle switch to the admin UI Settings page so administrators can
enable/disable custom API key values without making direct API calls.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-16 22:26:11 -07:00
Joe Reyna
966124966f
docs: add v1.82.3 release notes and update provider_endpoints_support.json (#23816) 2026-03-16 22:25:55 -07:00
Harshit Jain
d15c2d546e
fix: Register DynamoAI guardrail initializer and enum entry (#23752)
* fix: Register DynamoAI guardrail initializer and enum entry

Fix the "Unsupported guardrail: dynamoai" error by:
1. Adding DYNAMOAI to SupportedGuardrailIntegrations enum
2. Implementing initialize_guardrail() and registries in dynamoai/__init__.py

The DynamoAI guardrail was added in PR #15920 but never properly registered
in the initialization system. The __init__.py was missing the
guardrail_initializer_registry and guardrail_class_registry dictionaries
that the dynamic discovery mechanism looks for at module load time.

Fixes #22773

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>

* Update litellm/proxy/guardrails/guardrail_hooks/dynamoai/__init__.py

Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>

* Update litellm/proxy/guardrails/guardrail_hooks/dynamoai/__init__.py

Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>

* test: Add tests for DynamoAI guardrail registration

Verifies enum entry, initializer registry, class registry,
instance creation, and global registry discovery.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Haiku 4.5 <noreply@anthropic.com>
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-03-16 22:24:29 -07:00