main3.py 文件源码

python
阅读 37 收藏 0 点赞 0 评论 0

项目:foxpy 作者: plusreed 项目源码 文件源码
def on_command_error(error, ctx):
    if isinstance(error, commands.NoPrivateMessage):
        await fox.send_message(ctx.message.author, "Sorry, you can't use this command in private messages.")
    elif isinstance(error, commands.DisabledCommand):
        await fox.send_message(ctx.message.author, 'Sorry, it looks like that command is disabled.')
    elif isinstance(error, commands.CommandInvokeError):
        print('In {0.command.qualified_name}:'.format(ctx))
        traceback.print_tb(error.original.__traceback__)
        print('{0.__class__.__name__}: {0}'.format(error.original))
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号