litellm/tests/unit/proxy
devin-ai-integration[bot] 2d034bb35b
perf(proxy): hold one spend counter batch across admission and across post-call accounting (#43369)
Auth's spend counter MGET scope spans common checks, model budget check and reservation;
reservation increments go out as one pipeline; post-call reconcile adjustments ride the ordinary
increment pipeline and update_cache uses one batched read. Over-budget reservation counters are
charged one at a time so a rejection never touches the counters after it; post-call counter keys are
derived from ids without validating a UserAPIKeyAuth.

Resolves LIT-8881

Co-authored-by: yassin <yassin@berri.ai>
Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-09-29 15:05:33 -07:00
..
_experimental feat(mcp): scan and pin upstream tool descriptions (#43283) 2026-09-28 18:38:49 -07:00
auth perf(proxy): hold one spend counter batch across admission and across post-call accounting (#43369) 2026-09-29 15:05:33 -07:00
common_utils feat(router): opt in to prompt-cache cost routing (#43232) 2026-09-26 18:13:13 -07:00
db
example_config_yaml
google_endpoints
guardrails feat(guardrails): send a configured gateway_name from noma_v2 to Noma (#43678) 2026-09-29 10:20:40 -07:00
hooks fix(router): await budget redis pipeline before sync reads (internal copy of #32618) (#43125) 2026-09-24 22:27:13 -07:00
management_endpoints fix(ci): stop stale CI reds, keep unit tests off the host env, retry CyberArk policy conflicts (#43294) 2026-09-26 09:25:13 -07:00
management_helpers
middleware
public_endpoints
response_polling
spend_tracking
test_configs
__init__.py
conftest.py
test_aproxy_startup.py
test_credential_slot_registry.py test(proxy): classify every credential-bearing param for the canary suite (#43298) 2026-09-29 18:11:12 +00:00
test_custom_callback_input.py
test_custom_logger_s3_gcs.py
test_custom_tokenizer_bug.py
test_db_schema_changes.py
test_deprecated_key_grace_period.py
test_get_favicon.py
test_get_image.py
test_prisma_client_backoff_retry.py
test_prompt_test_endpoint.py
test_proxy_config_unit_test.py
test_proxy_custom_auth.py
test_proxy_reject_logging.py
test_proxy_server.py fix(ci): stop stale CI reds, keep unit tests off the host env, retry CyberArk policy conflicts (#43294) 2026-09-26 09:25:13 -07:00
test_proxy_setting_guardrails.py
test_proxy_token_counter.py
test_proxy_utils.py
test_reducto_ocr_route.py
test_response_polling_pre_call_checks.py
test_server_root_path.py
test_ui_path_detection.py
test_unit_test_proxy_hooks.py
test_update_spend.py
test_zero_cost_model_budget_bypass.py fix(proxy): resolve model_group_alias in the zero-cost budget predicate (#43512) 2026-09-28 21:46:33 -07:00
vertex_key.json