The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
[Fix] Finish uv migration for redis_caching, e2e_ui, and fix prisma/black in CI
Yuneng Jiangbb7ac7c4cad2
diff --git a/.circleci/config.yml b/.circleci/config.ymlindex 6606edc0c8f..428468919ee 100644--- a/.circleci/config.yml+++ b/.circleci/config.yml@@ -157,7 +157,7 @@ jobs:- restore_cache:keys:- - v1-dependencies-{{ checksum "uv.lock" }}+ - v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Install Dependenciescommand: |@@ -177,7 +177,7 @@ jobs:- save_cache:paths:- ./.venv- key: v1-dependencies-{{ checksum "uv.lock" }}+ key: v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Run prisma ./docker/entrypoint.shcommand: |@@ -247,7 +247,7 @@ jobs:- restore_cache:keys:- - v1-dependencies-{{ checksum "uv.lock" }}+ - v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Install Dependenciescommand: |@@ -267,7 +267,7 @@ jobs:- save_cache:paths:- ./.venv- key: v1-dependencies-{{ checksum "uv.lock" }}+ key: v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Run prisma ./docker/entrypoint.shcommand: |@@ -338,7 +338,7 @@ jobs:- restore_cache:keys:- - v1-dependencies-{{ checksum "uv.lock" }}+ - v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Install Dependenciescommand: |@@ -358,7 +358,7 @@ jobs:- save_cache:paths:- ./.venv- key: v1-dependencies-{{ checksum "uv.lock" }}+ key: v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Run prisma ./docker/entrypoint.shcommand: |@@ -407,7 +407,7 @@ jobs:- save_cache:paths:- ./.venv- key: v1-dependencies-{{ checksum "uv.lock" }}+ key: v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Run prisma ./docker/entrypoint.shcommand: |@@ -1031,7 +1031,7 @@ jobs:- run:name: Run proxy tests part 1 (high-volume directories)command: |- uv run --no-sync prisma generate+ uv run --no-sync python -m prisma generateexport PYTHONUNBUFFERED=1uv run --no-sync python -m pytest tests/test_litellm/proxy/guardrails tests/test_litellm/proxy/management_endpoints tests/test_litellm/proxy/_experimental tests/test_litellm/proxy/client tests/test_litellm/proxy/auth --junitxml=test-results/junit-proxy-part1.xml --durations=10 -n 4 --maxfail=5 --timeout=60 -vv --log-cli-level=WARNING -r Ano_output_timeout: 15m@@ -1050,7 +1050,7 @@ jobs:- run:name: Run proxy tests part 2 (all other tests)command: |- uv run --no-sync prisma generate+ uv run --no-sync python -m prisma generateexport PYTHONUNBUFFERED=1uv run --no-sync python -m pytest tests/test_litellm/proxy --ignore=tests/test_litellm/proxy/guardrails --ignore=tests/test_litellm/proxy/management_endpoints --ignore=tests/test_litellm/proxy/_experimental --ignore=tests/test_litellm/proxy/client --ignore=tests/test_litellm/proxy/auth --junitxml=test-results/junit-proxy-part2.xml --durations=10 -n 4 --maxfail=5 --timeout=120 -vv --log-cli-level=WARNING -r Ano_output_timeout: 15m@@ -1089,7 +1089,7 @@ jobs:command: |pwdls- uv run --no-sync prisma generate+ uv run --no-sync python -m prisma generateuv run --no-sync python -m pytest -v tests/enterprise -x --junitxml=test-results/junit-enterprise.xml --durations=10 -n 4no_output_timeout: 15m# Store test results@@ -1386,24 +1386,28 @@ jobs:steps:- checkout- setup_google_dns+ - restore_cache:+ keys:+ - v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Install Dependenciescommand: |- python -m pip install --upgrade 'pip==26.0.1' 'uv==0.10.9'- uv pip install --system -r requirements.txt- pip install "pytest==7.3.1"- pip install "pytest-retry==1.6.3"- pip install "pytest-cov==5.0.0"- pip install "pytest-asyncio==0.21.1"- pip install "pytest-xdist==3.6.1"- pip install "pytest-rerunfailures==14.0"+ curl -LsSf -o /tmp/uv-install.sh https://astral.sh/uv/0.10.9/install.sh+ echo "7fc46e39cb97290b57169c0c813a17970585ac519139f19006453c99b5f2f45f /tmp/uv-install.sh" | sha256sum -c -+ env UV_NO_MODIFY_PATH=1 sh /tmp/uv-install.sh+ rm -f /tmp/uv-install.sh+ echo 'export PATH="$HOME/.local/bin:$PATH"' >> "$BASH_ENV"+ export PATH="$HOME/.local/bin:$PATH"+ uv sync --frozen --all-groups --all-extras --python "$(which python)"+ - save_cache:+ paths:+ - ./.venv+ key: v2-dependencies-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}# Run pytest and generate JUnit XML report- run:name: Run testscommand: |- pwd- ls- python -m pytest -vv \+ uv run --no-sync python -m pytest -vv \tests/local_testing/test_dual_cache.py \tests/local_testing/test_redis_batch_optimizations.py \tests/local_testing/test_router_utils.py \@@ -3137,19 +3141,22 @@ jobs:- setup_google_dns- restore_cache:keys:- - ui-e2e-py-deps-v1-{{ checksum "requirements.txt" }}+ - ui-e2e-py-deps-v2-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}- run:name: Install Python dependenciescommand: |- python -m pip install --upgrade 'pip==26.0.1' 'uv==0.10.9'- uv pip install --system -r requirements.txt- pip install "prisma==0.11.0"- prisma generate --schema litellm/proxy/schema.prisma+ curl -LsSf -o /tmp/uv-install.sh https://astral.sh/uv/0.10.9/install.sh+ echo "7fc46e39cb97290b57169c0c813a17970585ac519139f19006453c99b5f2f45f /tmp/uv-install.sh" | sha256sum -c -+ env UV_NO_MODIFY_PATH=1 sh /tmp/uv-install.sh+ rm -f /tmp/uv-install.sh+ echo 'export PATH="$HOME/.local/bin:$PATH"' >> "$BASH_ENV"+ export PATH="$HOME/.local/bin:$PATH"+ uv sync --frozen --all-groups --all-extras --python "$(which python)"+ uv run --no-sync python -m prisma generate --schema litellm/proxy/schema.prisma- save_cache:- key: ui-e2e-py-deps-v1-{{ checksum "requirements.txt" }}+ key: ui-e2e-py-deps-v2-{{ checksum "uv.lock" }}-{{ checksum ".circleci/config.yml" }}paths:- - ~/.local/lib- - ~/.local/bin+ - ./.venv- restore_cache:keys:- ui-e2e-node-deps-v1-{{ checksum "ui/litellm-dashboard/package-lock.json" }}@@ -3178,7 +3185,7 @@ jobs:command: dockerize -wait tcp://localhost:5432 -timeout 30s- run:name: Push Prisma schema- command: prisma db push --schema litellm/proxy/schema.prisma --accept-data-loss+ command: uv run --no-sync python -m prisma db push --schema litellm/proxy/schema.prisma --accept-data-loss- run:name: Seed databasecommand: |@@ -3186,7 +3193,7 @@ jobs:-f ui/litellm-dashboard/e2e_tests/fixtures/seed.sql- run:name: Start mock LLM server- command: python ui/litellm-dashboard/e2e_tests/fixtures/mock_llm_server/server.py+ command: uv run --no-sync python ui/litellm-dashboard/e2e_tests/fixtures/mock_llm_server/server.pybackground: true- run:name: Start LiteLLM proxy@@ -3197,7 +3204,7 @@ jobs:SERVER_ROOT_PATH: ""PROXY_LOGOUT_URL: ""command: |- python -m litellm.proxy.proxy_cli \+ uv run --no-sync python -m litellm.proxy.proxy_cli \--config ui/litellm-dashboard/e2e_tests/fixtures/config.yml \--port 4000background: true