a2aproject / a2aproject/a2a-samples

LiteLLM ignores GOOGLE_GENAI_USE_VERTEXAI=FALSE environment variable and defaults to Vertex AI

Đang mở
#334 1 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Jupyter Notebook
Star
1.8k
Fork
751
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

### What happened?

When GOOGLE_GENAI_USE_VERTEXAI=FALSE is set, LiteLLM should use Google AI Studio with the GOOGLE_API_KEY, not attempt Vertex AI authentication.

LiteLLM defaults to Vertex AI regardless of the GOOGLE_GENAI_USE_VERTEXAI setting, causing authentication errors:

I have fixed the issue I will be raising the PR soon

### Relevant log output

```shell
litellm.exceptions.AuthenticationError: geminiException - {
"error": {
"code": 400,
"message": "API key not valid. Please pass a valid API key.",
"status": "INVALID_ARGUMENT",
"details": [
{
"@type": "type.googleapis.com/google.rpc.ErrorInfo",
"reason": "API_KEY_INVALID",
"domain": "googleapis.com",
"metadata": {
"service": "generativelanguage.googleapis.com"
}
}
]
}
}
```

### Code of Conduct

- [x] I agree to follow this project's Code of Conduct

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.