Coverage for /Users/eugene/Development/robotnikmq/robotnikmq/error.py: 64%
14 statements
« prev ^ index » next coverage.py v7.3.4, created at 2023-12-26 19:56 -0500
« prev ^ index » next coverage.py v7.3.4, created at 2023-12-26 19:56 -0500
1class UnableToConnect(Exception):
2 def __str__(self):
3 return f"{self.__class__.__name__}: Robotnik is unable to connect: {self.args}"
6class MalformedMessage(Exception):
7 def __init__(self, msg_input: str):
8 self.malformed_input = msg_input
9 super().__init__()
11 def __str__(self):
12 return f'Unable to decode RobotnikMQ message from: "{self.malformed_input}"'
15class InvalidConfiguration(Exception):
16 def __str__(self):
17 return (
18 f"{self.__class__.__name__}: Robotnik is improperly configured: {self.args}"
19 )
22class NotConfigured(Exception):
23 msg = "Robotnik is not configured"