Skip to content

Commit

Permalink
also handle generic error while streaming response
Browse files Browse the repository at this point in the history
  • Loading branch information
n3d1117 committed Mar 26, 2023
1 parent 90365c6 commit 50647ff
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bot/telegram_bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -375,6 +375,10 @@ async def prompt(self, update: Update, context: ContextTypes.DEFAULT_TYPE):
logging.warning(str(e))
await asyncio.sleep(1)

except Exception as e:
logging.warning(str(e))
continue

await asyncio.sleep(0.01)

i += 1
Expand Down

0 comments on commit 50647ff

Please sign in to comment.