litellm/tests/unit/rust_bridge/host
maciej-berri adaa460566
fix(messages): load the anthropic beta map only when a filter has a beta to filter (#52188)
* fix(messages): load the anthropic beta map only when a filter has a beta to filter

Since #52042 the Rust messages route asked Python for the beta map on every
azure_ai, Bedrock Invoke and Foundry call while decoding the request, so the
first such call on each worker downloaded the remote map even when it sent no
anthropic-beta, and the download ran synchronously on the request path.

The bridge now installs the map only once Python has loaded it. When a filter
first meets a beta and no map is installed, it asks the host to load it on the
loader thread and uses the compiled table for that call, as before #52042.

* fix(messages): start at most one background beta map load at a time

A burst of beta-carrying calls while the first download was still in flight
queued one load task per call on the loader thread. A non-blocking lock now
lets only one load wait in the queue, and it is released when that load ends.
2026-11-16 20:03:08 -08:00
..
routes fix(messages): load the anthropic beta map only when a filter has a beta to filter (#52188) 2026-11-16 20:03:08 -08:00
__init__.py
test_cache.py feat(messages): serve azure ai foundry messages on rust only (#51721) 2026-11-14 13:40:38 -08:00
test_callbacks_legacy_python.py feat(messages): serve bedrock invoke messages on rust only (#51330) 2026-11-15 16:58:31 -08:00
test_model_capabilities.py feat(messages): serve bedrock invoke messages on rust only (#51330) 2026-11-15 16:58:31 -08:00
test_model_cost.py fix(cost): keep a deployment's per-second video price over the catalog row's flat price (#51688) 2026-11-15 12:04:41 -08:00
test_preflight.py chore: move workspace packages under litellm (#51000) 2026-11-12 04:19:57 +00:00
test_redis_credentials.py feat(redis): extend the native Redis foundation for the store families (#50169) 2026-11-06 12:30:07 +09:00
test_redis_events.py refactor(router): count the whole router_usage family on the native store (#50862) 2026-11-13 03:22:28 +00:00
test_route_groups.py refactor(auth): decide route rules in Rust (#51531) 2026-11-16 18:55:32 +09:00
test_secret_manager.py refactor(rust_bridge): route every Rust-to-Python call through host modules (#50822) 2026-11-11 01:57:54 +00:00
test_settings.py fix(messages): close high and medium rust messages parity bugs (#52042) 2026-11-16 21:08:25 +00:00