Skip to content

Commit

Permalink
Update asyncio.gather to return exceptions.
Browse files Browse the repository at this point in the history
  • Loading branch information
eli64s committed Jan 23, 2024
1 parent 6ae121b commit 3beb6da
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions readmeai/core/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ async def _batch_prompts(

for batch in self._generate_batches(prompts, batch_size):
batch_responses = await asyncio.gather(
*[self._process_batch(prompt) for prompt in batch]
# , return_exceptions=True
*[self._process_batch(prompt) for prompt in batch],
return_exceptions=True,
)
responses.extend(batch_responses)

Expand Down Expand Up @@ -145,7 +145,7 @@ async def _set_prompt_context(
{
"repo": self.config.git.repository,
"dependencies": dependencies,
"files": summaries,
"summaries": summaries,
},
),
(
Expand Down

0 comments on commit 3beb6da

Please sign in to comment.