fix: stream end

Signed-off-by: yihong0618 <zouzou0208@gmail.com>
This commit is contained in:
yihong0618 2024-03-18 15:16:50 +08:00
parent 2a420ba745
commit 93a3e001c8
2 changed files with 12 additions and 1 deletions

View File

@ -155,6 +155,17 @@ def claude_pro_handler(message: Message, bot: TeleBot) -> None:
) )
except: except:
pass pass
try:
# maybe not complete
# maybe the same message
bot.edit_message_text(
message_id=reply_id.message_id,
chat_id=reply_id.chat.id,
text=convert(s),
parse_mode="MarkdownV2",
)
except:
pass
player_message.append( player_message.append(
{ {

2
tg.py
View File

@ -31,7 +31,7 @@ def main():
# Start bot # Start bot
print("Starting tg collections bot.") print("Starting tg collections bot.")
bot.infinity_polling(timeout=10, long_polling_timeout=5) bot.infinity_polling(timeout=40, long_polling_timeout=20)
if __name__ == "__main__": if __name__ == "__main__":