Skip to content

Commit

Permalink
Merge pull request #885 from Codium-ai/bugfix/hf_timeout
Browse files Browse the repository at this point in the history
Do not timeout when calling HF through acomplete
  • Loading branch information
krrishdholakia authored Nov 23, 2023
2 parents c51bfc6 + e74ac03 commit 6ba4eeb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion litellm/llms/huggingface_restapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,7 @@ async def acompletion(self,
response = None
try:
async with httpx.AsyncClient() as client:
response = await client.post(url=api_base, json=data, headers=headers)
response = await client.post(url=api_base, json=data, headers=headers, timeout=None)
response_json = response.json()
if response.status_code != 200:
raise HuggingfaceError(status_code=response.status_code, message=response.text, request=response.request, response=response)
Expand Down

0 comments on commit 6ba4eeb

Please sign in to comment.