0
点赞
收藏
分享

微信扫一扫

CSP-J复赛 模拟题4

GhostInMatrix 2024-08-07 阅读 20

问题描述:

在python3.7 版本 运行代码,报错

def retry( ignore_exception_type_info_list:list[IgnoreExceptionInfo]=None):


>>> TypeError: 'type' object is not subscriptable

解决方案:

去掉list内的参数推断,就正常了,似乎是python的一个bug
可以参考文章:https://github.com/krahets/hello-algo/issues/910

def retry( ignore_exception_type_info_list:list=None):

在这里插入图片描述

举报

相关推荐

0 条评论