mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-10-04 12:07:34 +00:00
fix: convert to string on return
The function signature expects a string to be returned by credentials.token is Any. So let's convert while we return to make mypy happy :) Signed-off-by: Sébastien Han <seb@redhat.com>
This commit is contained in:
parent
0e27016cf2
commit
cae696553c
1 changed files with 1 additions and 1 deletions
|
@ -41,7 +41,7 @@ class VertexAIInferenceAdapter(OpenAIMixin, LiteLLMOpenAIMixin):
|
|||
# Get default credentials - will read from GOOGLE_APPLICATION_CREDENTIALS
|
||||
credentials, _ = default(scopes=["https://www.googleapis.com/auth/cloud-platform"])
|
||||
credentials.refresh(google.auth.transport.requests.Request())
|
||||
return credentials.token
|
||||
return str(credentials.token)
|
||||
except Exception:
|
||||
# If we can't get credentials, return empty string to let LiteLLM handle it
|
||||
# This allows the LiteLLM mixin to work with ADC directly
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue