test(claude_code): pin vertex opus passthrough deployment to the global endpoint - #33552
test(claude_code): pin vertex opus passthrough deployment to the global endpoint#33552mateo-berri wants to merge 2 commits into
Conversation
Greptile SummaryThis PR pins
Confidence Score: 5/5Safe to merge — single config line change in an e2e test fixture, no production code affected. The change is a one-line value swap ( No files require special attention.
|
| Filename | Overview |
|---|---|
| tests/e2e/claude_code/test_config.yaml | Pins vertex_location: global for the claude-opus-4-7-vertex deployment to work around a zero-quota regional grant for opus-4-7 in the test project; haiku and sonnet stay regional, keeping both passthrough URL shapes exercised. |
Reviews (1): Last reviewed commit: "test(claude_code): pin vertex opus passt..." | Re-trigger Greptile
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
This was already completed |
Relevant issues
Follow-up to #33473, which documented the vertex opus passthrough cell as quota-blocked
Linear ticket
Pre-Submission checklist
Please complete all items before asking a LiteLLM maintainer to review your PR
@greptileaito re-request a review after pushing changes)Delays in PR merge?
If you're seeing a delay in your PR being merged, ping the LiteLLM Team on Slack (#pr-review).
Screenshots / Proof of Fix
No mocks: real
claudeCLI (2.1.210) against real Google Vertex AIBefore (captured at c4fee0e, in #33473): the vertex opus tier fails persistently while haiku and sonnet answer through the identical path in under 3s; three attempts spanning 490s, every one a token-quota 429
Root cause: the test project's Cloud Quotas grants for
online_prediction_input_tokens_per_minutecover every tier regionally except opus-4-7 (haiku-4-5 and sonnet-4-6 have 2M in the test region, opus-4-6 has 4M, opus-4-7 has no regional entry at all, i.e. an effective 0), while the global-endpoint quota family grants opus-4-7 16M input TPM. A ~15-tokenrawPredictstraight at Google confirms it with no CLI or proxy involved: instant 429 RESOURCE_EXHAUSTED regionally, 200 vialocations/globalAfter (config at e7ade2e, proxy image from the merged c59963e through the
tests/e2ecompose stack, same commands as #33473):docker compose -f tests/e2e/docker-compose.yml -f compose.override.yml up -d # port 52341 LITELLM_PROXY_BASE_URL=http://localhost:52341 LITELLM_PROXY_API_KEY=sk-multipod-qa \ python -m pytest tests/e2e/claude_code/passthrough -qThe vertex cell goes 3/3 with zero retry backoffs and the whole passthrough row drops from 498s to 13s. The CLI still sends its placeholder
CLOUD_ML_REGION=us-east5in the URL path, so the pass also proves the proxy substitutes the deployment'sgloballocation rather than echoing the client's region. The azure cell stays expected-red on theanthropic-versionforwarding gap documented in #33473; it is a separate proxy bug, not part of this changeType
✅ Test
Changes
Pins
vertex_location: globalon theclaude-opus-4-7-vertexdeployment intests/e2e/claude_code/test_config.yaml. The haiku and sonnet vertex deployments stay on the regionalVERTEXAI_LOCATION, which keeps both passthrough URL shapes under test: the regionalhttps://{region}-aiplatform.googleapis.comhost and the globalhttps://aiplatform.googleapis.com+locations/globalformQA runbook
LITELLM_MASTER_KEY=sk-1234 python litellm/proxy/proxy_cli.py --config tests/e2e/claude_code/test_config.yaml --port 4000withVERTEXAI_PROJECT,VERTEXAI_LOCATION, and Google ADC in the proxy envCLAUDE_CODE_USE_VERTEX=1 CLAUDE_CODE_SKIP_VERTEX_AUTH=1 ANTHROPIC_VERTEX_BASE_URL=http://localhost:4000/vertex_ai/v1 ANTHROPIC_VERTEX_PROJECT_ID=anything CLOUD_ML_REGION=us-east5 ANTHROPIC_AUTH_TOKEN=sk-1234 claude --print --model claude-opus-4-7-vertex "Reply with the single word 'pong' and nothing else."aiplatform.googleapis.com/v1/projects/{project}/locations/global/...from the deployment configEnvironment prerequisites and nuances are unchanged from #33473; the only new one is that the ADC project needs global-endpoint quota for opus-4-7, which is Google's default grant shape for this model
Final Attestation