Update api/utils.py
Browse files- api/utils.py +2 -2
api/utils.py
CHANGED
@@ -156,7 +156,7 @@ async def process_streaming_response(request: ChatRequest):
|
|
156 |
logger.error(f"HTTP error occurred for Chat ID {chat_id}: {e}")
|
157 |
raise HTTPException(status_code=e.response.status_code, detail=str(e))
|
158 |
except httpx.RequestError as e:
|
159 |
-
logger.error(f"
|
160 |
raise HTTPException(status_code=500, detail=str(e))
|
161 |
|
162 |
# Process non-streaming response with headers from config.py
|
@@ -217,7 +217,7 @@ async def process_non_streaming_response(request: ChatRequest):
|
|
217 |
logger.error(f"HTTP error occurred for Chat ID {chat_id}: {e}")
|
218 |
raise HTTPException(status_code=e.response.status_code, detail=str(e))
|
219 |
except httpx.RequestError as e:
|
220 |
-
logger.error(f"
|
221 |
raise HTTPException(status_code=500, detail=str(e))
|
222 |
|
223 |
if full_response.startswith("$@$v=undefined-rv1$@$"):
|
|
|
156 |
logger.error(f"HTTP error occurred for Chat ID {chat_id}: {e}")
|
157 |
raise HTTPException(status_code=e.response.status_code, detail=str(e))
|
158 |
except httpx.RequestError as e:
|
159 |
+
logger.error(f"Request error occurred for Chat ID {chat_id}: {e}")
|
160 |
raise HTTPException(status_code=500, detail=str(e))
|
161 |
|
162 |
# Process non-streaming response with headers from config.py
|
|
|
217 |
logger.error(f"HTTP error occurred for Chat ID {chat_id}: {e}")
|
218 |
raise HTTPException(status_code=e.response.status_code, detail=str(e))
|
219 |
except httpx.RequestError as e:
|
220 |
+
logger.error(f"Request error occurred for Chat ID {chat_id}: {e}")
|
221 |
raise HTTPException(status_code=500, detail=str(e))
|
222 |
|
223 |
if full_response.startswith("$@$v=undefined-rv1$@$"):
|