litellm/litellm
mateo-berri 12a34a10d8 fix(logging_worker): carry queued tasks across event-loop change instead of dropping them
LoggingWorker._ensure_queue nulled self._queue on a loop change, discarding every
pending LoggingTask (each an un-awaited spend-logging coroutine) with no counter and
only a debug log. SDK callers using asyncio.run() per request and mixed sync/async
processes rebind the queue's loop and silently lose spend rows and observability events.

Drain the stale queue and move the pending tasks onto a fresh queue bound to the new
loop, warn with the carried-over count, and keep flush()/join() honest since the queue
is no longer thrown away. Adds a regression test that fills the queue before the loop
change and asserts every task survives and still executes.
2026-08-24 13:46:09 -07:00
..
a2a_protocol fix(a2a): speak the 0.3 dialect to servers with mis-cased protocol bindings 2026-08-24 10:51:14 -07:00
anthropic_interface chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
assistants chore(lint): clear grandfathered over-limit lint drift and ratchet budgets down 2026-08-05 12:18:13 -07:00
batch_completion feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
batches fix(batches): decode model-encoded output file id so completed batches book spend 2026-08-19 20:16:22 -07:00
caching fix(redis): reset only the failed node on a cluster client timeout, not the whole client (#37863) 2026-08-21 22:00:06 +00:00
completion_extras fix(responses-adapter): skip null reasoning summary text and keep thinking-only assistant turns 2026-08-22 16:29:35 -07:00
compression chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
containers chore(typing): drop 1.3k basedpyright errors across 30 Any hotspot files 2026-08-16 03:56:02 +00:00
endpoints/speech/speech_to_completion_bridge feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
evals chore(typing): remove 914 basedpyright Any errors across 16 hotspot files 2026-08-10 01:24:40 -07:00
experimental_mcp_client fix(mcp): normalize auth schemes so MCP egress emits exactly one prefix (#37668) 2026-08-20 14:11:38 -07:00
files fix(batches): accept litellm_proxy in files and batches provider type literals 2026-08-18 13:28:06 -07:00
fine_tuning Merge branch 'litellm_internal_staging' into litellm_remove_types_ruff_exclusion 2026-08-05 11:05:33 -07:00
google_genai chore(typing): drop 1.3k basedpyright errors across 42 Any hotspot files 2026-08-19 01:12:41 +00:00
images Merge origin/litellm_internal_staging into litellm_fix_36493_image_video_routes 2026-08-24 11:58:22 -07:00
integrations feat(newrelic): per-team New Relic trace routing via team callbacks (#37603) 2026-08-22 19:13:48 -07:00
interactions fix(interactions): poll queued background creates and drop the poll's deployment identity 2026-08-22 17:35:19 -07:00
litellm_core_utils fix(logging_worker): carry queued tasks across event-loop change instead of dropping them 2026-08-24 13:46:09 -07:00
llms Merge pull request #38104 from BerriAI/litellm_fix_36493_image_video_routes 2026-08-24 13:17:03 -07:00
models feat(spend-logs): add lifecycle timestamps 2026-08-18 14:16:08 -07:00
ocr fix(ocr): reject invalid req_format values as 400 on the SDK path 2026-08-17 15:49:18 -07:00
passthrough fix(passthrough): protect accept-encoding from x-pass- forwarding 2026-08-15 15:34:28 -07:00
proxy Merge pull request #38104 from BerriAI/litellm_fix_36493_image_video_routes 2026-08-24 13:17:03 -07:00
proxy_auth feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
rag chore(typing): remove 914 basedpyright Any errors across 16 hotspot files 2026-08-10 01:24:40 -07:00
realtime_api fix(realtime): resolve the vertex token resolver at call time 2026-08-20 02:49:01 -07:00
repositories chore(typing): drop 1.3k basedpyright errors across 42 Any hotspot files 2026-08-19 01:12:41 +00:00
rerank_api chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
responses chore(responses): keep the session lookup inside the type-discipline budget 2026-08-22 15:25:59 -07:00
router_strategy feat(complexity_router): add business classification rubric preset (#37534) 2026-08-20 11:20:53 -07:00
router_utils fix(router): make prompt caching affinity aware of auto-injected cache_control (#37689) 2026-08-20 16:10:27 -07:00
rust_bridge feat(rust): route /chat/completions through the Rust core for anthropic and bedrock (#37241) 2026-08-20 16:15:24 -07:00
sandbox feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
search chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
secret_managers fix(azure): prefer workload identity over managed identity 2026-08-20 13:45:56 -07:00
skills chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
types Merge pull request #38115 from BerriAI/litellm_fix_runwayml_video_provider 2026-08-24 12:35:59 -07:00
vector_store_files chore(lint): clear grandfathered over-limit lint drift and ratchet budgets down 2026-08-05 12:18:13 -07:00
vector_stores chore(typing): drop 1.3k basedpyright errors across 30 Any hotspot files 2026-08-16 03:56:02 +00:00
videos chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
__init__.py Merge remote-tracking branch 'origin/litellm_internal_staging' into litellm_block_unpriced_models 2026-08-20 13:43:12 -07:00
_internal_context.py feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
_lazy_imports.py fix(lint): bring basedpyright rule counts back under their budget limits 2026-08-05 10:23:02 -07:00
_lazy_imports_registry.py chore(lint): clear grandfathered over-limit lint drift and ratchet budgets down 2026-08-05 12:18:13 -07:00
_logging.py fix(logging): preserve uvicorn color_message args during secret redaction (#37122) 2026-08-21 16:04:53 -07:00
_redis.py fix(redis): reset only the failed node on a cluster client timeout, not the whole client (#37863) 2026-08-21 22:00:06 +00:00
_redis_credential_provider.py chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
_service_logger.py chore(lint): clear grandfathered over-limit lint drift and ratchet budgets down 2026-08-05 12:18:13 -07:00
_uuid.py chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
_version.py
anthropic_beta_headers_config.json fix(bedrock-invoke): retain clear_tool_uses_20250919 context_management edits and emit context-management-2025-06-27 beta (LIT-3393) (#32658) 2026-07-09 14:31:27 -07:00
anthropic_beta_headers_manager.py feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
blog_posts.json
budget_manager.py feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
constants.py Merge pull request #33310 from BerriAI/litellm_google_interactions_cost 2026-08-24 11:18:58 -07:00
cost.json
cost_calculator.py Merge pull request #38115 from BerriAI/litellm_fix_runwayml_video_provider 2026-08-24 12:35:59 -07:00
exceptions.py feat(proxy): redact or drop individual batch records instead of rejecting the file (#37561) 2026-08-20 13:12:55 -07:00
main.py Merge origin/litellm_internal_staging into litellm_azure_ai_entra_auth 2026-08-24 11:33:18 -07:00
model_prices_and_context_window_backup.json Merge pull request #38115 from BerriAI/litellm_fix_runwayml_video_provider 2026-08-24 12:35:59 -07:00
policy_templates_backup.json
provider_endpoints_support_backup.json fix(scx-ai): use the published scx.ai rates and the scx_ai docs url 2026-08-21 17:28:12 +10:00
py.typed
router.py fix(ptu): warn when config.yaml declares PTU while attribution is off (#37898) 2026-08-22 08:25:16 -07:00
scheduler.py feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
setup_wizard.py chore(lint): strip inert type: ignore comments and zero LIT009, LIT010, LIT011 headroom 2026-08-05 02:37:24 -07:00
timeout.py feat(lint): enforce Final on locals and freeze function parameters (LIT010, LIT011) 2026-08-04 12:54:39 -07:00
utils.py Merge pull request #38115 from BerriAI/litellm_fix_runwayml_video_provider 2026-08-24 12:35:59 -07:00