Skip to content

Commit

Permalink
change logs
Browse files Browse the repository at this point in the history
  • Loading branch information
RyanMarten committed Dec 16, 2024
1 parent 999e579 commit 9fd48cf
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -486,8 +486,9 @@ async def handle_single_request_with_retries(
if request.attempts_left > 0:
request.attempts_left -= 1
logger.warning(
f"Request {request.task_id} failed with Exception: {e} "
f"Retries left: {request.attempts_left}"
f"Encountered '{e.__class__.__name__}: {e}' during attempt "
f"{self.max_retries - request.attempts_left} of {self.max_retries} "
f"while processing request {request.task_id}"
)
retry_queue.put_nowait(request)
else:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ async def call_single_request(
logger.debug(
f"finish_reason {finish_reason} was not 'stop' with raw response {completion_obj.model_dump()} for request {request.generic_request.messages}"
)
raise ValueError(f"finish_reason was {finish_reason} ")
raise ValueError(f"finish_reason was {finish_reason}")

if response_message is None:
raise ValueError(
Expand Down

0 comments on commit 9fd48cf

Please sign in to comment.