mirror of
https://github.com/PaiGramTeam/PaiGram.git
synced 2025-02-02 08:25:20 +00:00
🎨 修改发送错误时回复的错误信息
This commit is contained in:
parent
ac93c71526
commit
e770efbc8b
@ -76,9 +76,8 @@ async def error_handler(update: object, context: CallbackContext) -> None:
|
||||
Log.info(f"尝试通知用户 {effective_user.full_name}[{effective_user.id}] "
|
||||
f"在 {chat.full_name}[{chat.id}]"
|
||||
f"的 update_id[{update.update_id}] 错误信息")
|
||||
text = f"派蒙这边发生了点问题无法处理!\n" \
|
||||
f"如果当前有对话请发送 /cancel 退出对话。\n" \
|
||||
f"错误信息为 <code>{html.escape(str(context.error))}</code>"
|
||||
text = f"出错了呜呜呜 ~ 派蒙这边发生了点问题无法处理!\n" \
|
||||
f"如果当前有对话请发送 /cancel 退出对话。\n"
|
||||
await context.bot.send_message(message.chat_id, text, reply_markup=ReplyKeyboardRemove(),
|
||||
parse_mode=ParseMode.HTML)
|
||||
except BadRequest as exc:
|
||||
|
Loading…
Reference in New Issue
Block a user