From be447d0ea7fc30b7bd7bdfe730532f20a3f00b77 Mon Sep 17 00:00:00 2001 From: Mole Shang <135e2@135e2.dev> Date: Wed, 25 Jan 2023 13:54:47 +0800 Subject: fix(bot.py): update callback params... ... following the new 20.0 api here: https://github.com/python-telegram-bot/python-telegram-bot/wiki/Extensions-%E2%80%93-JobQueue --- bot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot.py b/bot.py index 68be042..11fc201 100644 --- a/bot.py +++ b/bot.py @@ -94,7 +94,7 @@ async def periodic_task(context: CallbackContext) -> None: mail = client.get_mail_by_index(i + 1) content = mail.__repr__() for text in handle_large_text(content): - await context.bot.send_message(context.job.context, text=text) + await context.bot.send_message(context.job.chat_id, text=text) inbox_num = new_inbox_num -- cgit v1.2.3