Исходный код cdek.exceptions.cdek_exception

from .. import constants


[документация] class CdekException(Exception): """Базовое исключение для CDEK"""
[документация] @staticmethod def get_translation(code: str, message: str) -> str: """Получить перевод ошибки""" if code in constants.ERRORS: return f"{constants.ERRORS[code]}. {message}" return message