class DefaultException(Exception):
    default_message = "Что то пошло не так"
    error_code = "ErrorCodeNotDefined"

    def __init__(self, message=None):
        self.message = message if message else self.default_message
        self.error_code = self.error_code
