litellm/tests/test_litellm
ishaan-berri d24240c014
feat(ui): agent traces open in a side drawer with a chat-style run view (#43972)
* feat(ui): redesign agent trace run view with chat-style detail pane

Tree with connector lines, typed icon tiles and provider logos, hover
cards with timing, and Input/Output sections rendered as message cards.

* fix(tracing): show text for block-list message content and split normalizers per convention

OpenAI responses-style content (reasoning + text blocks) rendered as raw
JSON in the trace view. Keep the text blocks and drop opaque reasoning.

Move each convention into litellm/tracing/normalizers with an ordered
registry so new frameworks plug in without touching OTLP decoding.

* fix(tracing): keep long message histories as valid JSON and parse function_call blocks

* feat(ui): open agent traces in a resizable side drawer with a devtool-style tree

Clicking a run opens it in a drawer over the list instead of a full page.
j/k and the header arrows switch runs, Esc closes. The tree gets dashed
connectors, per-span waterfall bars, mono tool names and real provider
logos. AI messages with reasoning/function_call blocks render as text.

* fix(trace-ui): address review: valid JSON trimming, drawer keys, reduced motion, narrow screens

* feat(tracing): serve span content in a standard LiteLLM UI format

GET /v1/traces/{trace_id}/spans/{span_id} now also returns input_ui and
output_ui, a tagged union of messages, fields or text built server side by
litellm/tracing/ui_format.py. The trace UI renders from those fields and only
falls back to client-side parsing when talking to an older proxy. The raw
input and output strings are unchanged, and so is storage

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

* fix(tracing): fall back to an elision marker when shortened messages still exceed the size limit

* fix(tracing): keep both messages when tool_calls are oversized and keep failed-tool styling

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-01 17:55:51 +00:00
..
integrations/clickhouse feat(lens): analyze agent activity with a separate worker (#43889) 2026-09-30 22:42:09 +00:00
proxy feat(ui): agent traces open in a side drawer with a chat-style run view (#43972) 2026-10-01 17:55:51 +00:00
tracing feat(ui): agent traces open in a side drawer with a chat-style run view (#43972) 2026-10-01 17:55:51 +00:00
__init__.py
conftest.py test: move tests/test_litellm core utils, routing, responses, caching and rust_bridge into tests/unit (#43199) 2026-09-25 17:10:13 -07:00
readme.md
test_check_unbounded_in_lists.py ci: fail on new unbounded SQL IN lists and add a Prisma chunking helper (#42629) 2026-09-26 13:40:44 -07:00
test_conftest.py test(proxy): move management_endpoints, management_helpers and guardrails tests into tests/unit/proxy (#44003) 2026-10-01 10:52:03 -07:00

Testing for litellm/

This directory 1:1 maps the the litellm/ directory, and can only contain mocked tests.

The point of this is to:

  1. Increase test coverage of litellm/
  2. Make it easy for contributors to add tests for the litellm/ package and easily run tests without needing LLM API keys.

File name conventions

  • litellm/proxy/test_caching_routes.py maps to litellm/proxy/caching_routes.py
  • test_<filename>.py maps to litellm/<filename>.py