Spaces:
Running
Running
Update app/routes/chat_api.py
Browse files- app/routes/chat_api.py +1 -1
app/routes/chat_api.py
CHANGED
@@ -108,7 +108,7 @@ async def chat_completions(fastapi_request: Request, request: OpenAIRequest, api
|
|
108 |
rotated_credentials, rotated_project_id = credential_manager_instance.get_random_credentials()
|
109 |
if rotated_credentials and rotated_project_id:
|
110 |
try:
|
111 |
-
client_to_use = genai.Client(vertexai=True, credentials=rotated_credentials, project=rotated_project_id, location="
|
112 |
print(f"INFO: Using rotated credential for project: {rotated_project_id}")
|
113 |
except Exception as e:
|
114 |
print(f"ERROR: Rotated credential client init failed: {e}. Falling back.")
|
|
|
108 |
rotated_credentials, rotated_project_id = credential_manager_instance.get_random_credentials()
|
109 |
if rotated_credentials and rotated_project_id:
|
110 |
try:
|
111 |
+
client_to_use = genai.Client(vertexai=True, credentials=rotated_credentials, project=rotated_project_id, location="global")
|
112 |
print(f"INFO: Using rotated credential for project: {rotated_project_id}")
|
113 |
except Exception as e:
|
114 |
print(f"ERROR: Rotated credential client init failed: {e}. Falling back.")
|