fix: markdown format

This commit is contained in:
yihong0618
2023-12-17 22:56:54 +08:00
parent cb739306ec
commit e56b35cfd1
3 changed files with 116 additions and 5 deletions

View File

@ -48,9 +48,13 @@ def wrap_handler(handler: T, bot: TeleBot) -> T:
bot.reply_to(message, "Please provide info after start words.")
return
return handler(message, *args, **kwargs)
except Exception:
except Exception as e:
traceback.print_exc()
bot.reply_to(message, "Something wrong, please check the log")
# handle more here
if str(e).find("RECITATION") > 0:
bot.reply_to(message, "Your prompt `RECITATION` please check the log")
else:
bot.reply_to(message, "Something wrong, please check the log")
return update_wrapper(wrapper, handler)