1234567891011121314151617181920212223242526272829303132333435 |
- class JyBasicException(Exception):
- def __init__(self, code: int, reason: str, **kwargs):
- self.code = code
- self.reason = reason
- self.err_details = kwargs
- for key, val in kwargs.items():
- setattr(self, key, val)
- class CustomCheckError(JyBasicException):
- def __init__(self, code: int = 10002, reason: str = '特征条件检查异常', **kwargs):
- self.code = code
- self.reason = reason
- self.err_details = kwargs
- for key, val in kwargs.items():
- setattr(self, key, val)
- class AttachmentNullError(JyBasicException):
- def __init__(self, code: int = 10004, reason: str = '附件下载异常', **kwargs):
- self.code = code
- self.reason = reason
- self.err_details = kwargs
- for key, val in kwargs.items():
- setattr(self, key, val)
- class CustomAccountPrivilegeError(JyBasicException):
- def __init__(self, *args, **kwargs):
- pass
|