python try except 捕捉错误得到错误的时候的值

try:
  dict_reason = self.get(name,id_number,mobile,card_number,**kwargs)
except RetryError as e:

  # 获取错误的结果
  error_info= e.args
  print(error_info)

posted @ 2018-01-08 16:02  shmily3929  阅读(843)  评论(0编辑  收藏  举报