You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
11 lines
274 B
11 lines
274 B
"""
|
|
基础异常类
|
|
"""
|
|
|
|
|
|
class BusinessError(Exception):
|
|
"""业务逻辑错误基类"""
|
|
def __init__(self, message: str, error_code: str = "BUSINESS_ERROR"):
|
|
self.message = message
|
|
self.error_code = error_code
|
|
super().__init__(self.message)
|