Commit graph

533 commits

Author SHA1 Message Date
Mateo Wang
2e06d195b2
Merge pull request #39857 from BerriAI/litellm_e2e_reliability_module_cells
test(e2e): cover the reliability retry, cooldown, fallback, and routing-strategy cells
2026-09-15 11:38:51 -07:00
yuneng-jiang
81863c1b17
Merge pull request #41188 from BerriAI/litellm_spend_reconciliation
test(spend): reconcile concurrent requests and daily activity
2026-09-15 00:32:20 -07:00
Yuneng Jiang
7a7770db0d
test(e2e): verify streamed answers and tool continuation 2026-09-14 22:46:55 -07:00
Yuneng Jiang
80d804d6f9
test(spend): preserve multi-day coverage and immutable assertions 2026-09-14 22:26:20 -07:00
Yuneng Jiang
7e3d7178b4
test(spend): reconcile concurrent requests and daily activity 2026-09-14 21:52:01 -07:00
Yuneng Jiang
16fb44f23a
ci: run provider replay harness in CircleCI 2026-09-14 21:03:58 -07:00
yuneng-jiang
9d7f2aad04
Merge branch 'main' into litellm_strict_provider_identity 2026-09-14 20:43:55 -07:00
yuneng-jiang
15bd8b0e4a
Merge pull request #40892 from BerriAI/litellm_jwt_management_callers
test: bind management E2E callers and isolate JWT actors
2026-09-14 20:30:52 -07:00
Yuneng Jiang
37bde0bdbe
test: keep provider request snapshots immutable 2026-09-14 17:27:18 -07:00
Yuneng Jiang
51db940514
test: relocate strict replay harness coverage 2026-09-14 17:20:58 -07:00
Yuneng Jiang
b9c194076a
test: preserve strict replay numeric spelling 2026-09-14 17:11:56 -07:00
Yuneng Jiang
6604c78120
test: add strict stateless provider replay identity 2026-09-14 16:55:43 -07:00
Yassin Kortam
036bfc08fc
docs(e2e): ban unit tests under tests/e2e (#33852)
The e2e harness exists to prove product features end to end against a live
proxy. The prior Hard Rule carved out an exception for "tests that cover the
harness itself" and pointed at coverage_registry/test_collector.py, which in
practice invited unit tests of harness helpers to be staged alongside e2e
work. That is the wrong tool: harness logic that is worth locking down does
not need a mock-driven unit test living under tests/e2e.

Drop the carve-out. The Hard Rule now reads that no unit tests of any kind
belong under tests/e2e, and the passing mention of unmarked harness coverage
in the transport section is removed so the doc no longer contradicts itself.

coverage_registry/test_collector.py still exists on disk and is left in place
for now; whether to relocate or remove it is a separate decision.
2026-09-12 21:13:43 -07:00
mateo-berri
6db93a930f test(e2e): skip the override strategy cells and describe the 1s cooldown cache 2026-09-12 17:56:23 -07:00
Joshua Valluru
94e4dd725f fix(mcp): require admission for delegated OAuth 2026-09-12 16:41:23 -07:00
Yuneng Jiang
c8bb54993e
test: enforce isolated actors and stop OIDC process groups 2026-09-12 13:49:49 -07:00
Yuneng Jiang
88de192dcf
test: bind management E2E callers and isolate JWT actors 2026-09-12 13:29:04 -07:00
mateo-berri
036a380fa0 chore: merge litellm_internal_staging into litellm_e2e_reliability_module_cells
Some checks failed
ai-gateway image / ai-gateway release image (push) Waiting to run
LiteLLM Rust / rust-lint (push) Waiting to run
LiteLLM Rust / rust-test (push) Waiting to run
Terraform Modules / fmt, validate, test (aws) (push) Has been cancelled
Terraform Modules / fmt, validate, test (gcp) (push) Has been cancelled
Terraform Provider / gofmt, vet, build, test (push) Has been cancelled
Terraform Provider / Provider endpoints vs proxy OpenAPI schema (push) Has been cancelled
2026-09-12 13:05:02 -07:00
yuneng-jiang
5f73f837ec
Merge pull request #40774 from BerriAI/litellm_cache_response_semantics
test(e2e): verify cached answers and upstream request count
2026-09-12 12:11:57 -07:00
Yuneng Jiang
fa470f01ad
fix(keys): preserve audit null and qualify split deployments 2026-09-11 22:33:36 -07:00
Yuneng Jiang
b571193c5d
fix(keys): support explicit project detachment 2026-09-11 22:09:40 -07:00
yuneng-jiang
1be89d28b8
Merge pull request #39990 from BerriAI/litellm_e2e_jwt_harness
test(e2e): reusable JWT fixtures and management lifecycle coverage
2026-09-11 21:18:59 -07:00
mateo-berri
9ba7ec2964 test(e2e): keep the memory regression case in a class and drop the helper docstrings 2026-09-11 19:46:06 -07:00
mateo-berri
a8ffc852f2 test(e2e): trim the reliability helper docstrings to the cooldown rationale 2026-09-11 19:32:40 -07:00
mateo-berri
9375719feb Merge remote-tracking branch 'origin/litellm_internal_staging' into litellm_e2e_memory_regression_failing_requests
# Conflicts:
#	tests/e2e/CLAUDE.md
#	tests/e2e/models.py
2026-09-11 19:31:11 -07:00
Yuneng Jiang
a706dbbb7d
chore: merge current staging into JWT E2E infrastructure 2026-09-11 17:13:52 -07:00
Yuneng Jiang
77f406dc00
test(e2e): start persistent Keycloak in the changed-test runner 2026-09-11 17:09:35 -07:00
kerry-berri
8e4f2abb40
Merge pull request #40482 from BerriAI/litellm_e2e_redis_timeout
test(load): add a Redis timeout chaos load test
2026-09-11 16:58:52 -07:00
Yuneng Jiang
4dd6af5722
chore: merge latest staging into JWT E2E foundation 2026-09-11 16:46:20 -07:00
Yuneng Jiang
f7b1fdc39c
test(e2e): check cleanup warnings through one teardown action 2026-09-11 16:43:31 -07:00
Yuneng Jiang
9a80bf2ad4
test(e2e): harden JWT fixtures and cover management lifecycles 2026-09-11 16:36:12 -07:00
kerry
ffc16a4b0e test(e2e): restore the E2E_REDIS_CHAOS opt-in for the redis chaos test
Some checks failed
LiteLLM Rust / rust-lint (push) Has been cancelled
LiteLLM Rust / rust-test (push) Has been cancelled
Terraform Modules / fmt, validate, test (aws) (push) Has been cancelled
Terraform Modules / fmt, validate, test (gcp) (push) Has been cancelled
Terraform Provider / gofmt, vet, build, test (push) Has been cancelled
Terraform Provider / Provider endpoints vs proxy OpenAPI schema (push) Has been cancelled
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
2026-09-11 22:46:31 +00:00
Kerry Lu
d4e083348c revert: drop the create-release.yml gating and E2E_REDIS_CHAOS opt-in
create-release.yml is back to calling the chaos test through no mechanism at
all; it never called it. Also drops the E2E_REDIS_CHAOS opt-in gate itself:
the redis_chaos marker still exists for -m selection and is still excluded
from the per-PR selector by path (tests/e2e/(ui|claude_code|load)/), but the
test no longer needs an env var to run once its file is targeted.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 15:16:00 -07:00
Kerry Lu
7d8f2c9ad3 ci(e2e): drop the weekly cron for the Redis chaos test
Now that create-release.yml gates stable and RC releases on this test directly,
the weekly schedule is redundant: every release gets a run against its own
commit instead of whatever happened to be on the default branch that Saturday.
workflow_dispatch stays for manual runs.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 15:00:57 -07:00
Kerry Lu
93c8ef1beb docs(e2e): note the release gate in the load/ harness guide
Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 14:40:08 -07:00
Kerry Lu
0ea18f28af test(e2e): tighten chaos log-bytes ceiling to 10 KB per request
Local runs measured 3.5 KB per request, so 10 KB keeps close to 3x headroom
while tightening from the earlier 12 KB.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 13:45:42 -07:00
Kerry Lu
a1f9f4cbe8 test(e2e): tighten chaos latency ceilings to 1s/2s/3s
Local runs measured p50 0.19s, p90 0.23s, p99 0.69s, so 2s/3s/5s left several
times that as slack. 1s/2s/3s keeps a comfortable margin while catching a
smaller regression than the looser ceilings would have.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 13:45:11 -07:00
Kerry Lu
e81a788776 test(e2e): hold chaos CPU per request to 2x
Three local runs measured 1.33x-1.36x, so 2x is the tightest bound the data
supports and still catches a regression far smaller than 4x would. Noted in the
comment that this is the ceiling to loosen first if a weekly run trips it,
since core count shifts how much of baseline CPU is fixed per-request work.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 13:43:53 -07:00
Kerry Lu
1d71006567 test(e2e): tighten chaos RSS and CPU ceilings to what runs actually measured
RSS moved 0.91x-1.40x across three identical local runs, so it stays loose at
2x rather than the arbitrary 1.5x carried over from the pre-padding-payload
calibration. CPU per request held steady at 1.33x-1.36x across the same runs,
so 4x replaces the looser 6x it inherited from stale numbers.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 13:43:18 -07:00
Kerry Lu
cc1d2c66c8 test(e2e): bound chaos latency and log volume with flat ceilings
A ratio against the healthy phase cannot bound either metric. Once the Redis
circuit breaker opens, a request skips Redis instead of waiting on its socket
timeout, so the chaos phase can measure cheaper than the baseline it is compared
against: local runs came in at 0.61x baseline p90 while a log-bytes ratio read
724x. Splitting Budget into RatioBudget and AbsoluteBudget lets RSS and CPU keep
the ratio they need, since both are machine-shaped, while latency and log volume
get the wall-clock ceiling a user actually cares about.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 13:38:01 -07:00
Kerry Lu
66980bbb87 test(e2e): address Redis chaos PR review, add log-bytes budget
Pad the locust payload to tens of KB so per-request bookkeeping cost scales with
body size instead of hiding behind a 40-byte prompt. Turn on
use_redis_transaction_buffer in the chaos config and JSON_LOGS in the workflow so
the spend buffer, pod lock, and JSON-encoded breaker tracebacks are all part of
the measured chaos cost. Add a log-bytes-per-request budget alongside latency,
RSS, and CPU, reading the proxy's log file size at each phase split; its ceiling
is uncalibrated since no chaos run has measured it yet.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 12:40:25 -07:00
Kerry Lu
1270ecb781 test(load): drive /v1/messages alongside /chat/completions in the Redis chaos test
The Anthropic Messages route reaches the same Redis touchpoints and cost-tracking
callback through its own request path, so a failure-path regression there would not
surface from chat completions alone. Each simulated user now picks one endpoint round
robin and stays on it, and the per-endpoint split is asserted and reported so a run
that silently drove only one route fails instead of passing.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 12:28:02 -07:00
Yuneng Jiang
866d94ed23
test(e2e): verify cached answers and upstream request count 2026-09-11 12:10:19 -07:00
Kerry Lu
1699f2d6dc Merge remote-tracking branch 'origin/litellm_internal_staging' into litellm_e2e_redis_timeout
# Conflicts:
#	uv.lock
2026-09-11 11:38:22 -07:00
Kerry Lu
5f17261534 test(load): pause Redis outright and budget the chaos phase against the baseline
CLIENT PAUSE ALL for the length of the chaos phase instead of CLIENT PAUSE WRITE, so every Redis touchpoint on the request path times out rather than just the writes. The pause is sized to the phase because it freezes the control connection too; teardown's CLIENT UNPAUSE is a safety net for a phase that overran

Latency, RSS and CPU are now budgeted as chaos-over-baseline ratios (p50/p90/p99 for latency and RSS, CPU seconds per request once) through a small phase_budget module, replacing the machine-shaped absolutes. The Redis timeout rate is reported but no longer asserted

The final /metrics scrape waits for litellm_deployment_failure_responses_total to stop moving, since that counter is bumped from the async logging queue and lagged the load generator by thousands of increments. The model group carries a unique marker so a deployment left behind by an aborted run cannot absorb this run's retries

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-11 11:06:06 -07:00
Yuneng Jiang
b01d12154d
test(e2e): budget model health setup and propagation waits 2026-09-11 10:39:49 -07:00
Yuneng Jiang
057d333d10
test(e2e): observe model propagation without pre-running health checks 2026-09-11 10:29:10 -07:00
Yuneng Jiang
5ddd839432
test(e2e): wait for serving propagation in UI journeys 2026-09-11 10:25:43 -07:00
Kerry Lu
33ec56ed75 test(e2e): rewrite the Redis timeout test as a locust chaos load test
The sequential version sent one request at a time, so a Redis outage never
reached the concurrency where the failed-tracking alert body actually grows.
This drives the proxy with locust against one model group of three mock
deployments, two failing at order 1 and one serving at order 2, so every
request spends its retries on the failing pair and lands on the serving
deployment through the order-based fallback. Two phases, a healthy baseline
and a CLIENT PAUSE WRITE window, and every request must succeed in both.

Latency, RSS and CPU are reported as p50/p90/p99 per phase rather than
asserted on: RSS and CPU come from psutil on the proxy's process tree, since
a multi-worker proxy serves /metrics from the prometheus multiprocess
collector and that drops the process collector's series. Thresholds stay open
until weekly runs give real baselines.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-10 21:55:23 -07:00
mateo-berri
77a0053a20 test(e2e): require the same workers at both memory checkpoints
Each checkpoint now samples until no new worker has answered for the settle
window, and the growth assertion refuses a worker set that changed between the
warm and after checkpoints instead of comparing only the intersection, so a
leaking worker reached by one checkpoint alone cannot drop out of the gate
2026-09-10 19:47:11 -07:00