Initialize command error. Args: message: Error message command: Command name that failed (optional)
(self, message: str, command: str | None = None)
| 8 | """Base exception for all command errors.""" |
| 9 | |
| 10 | def __init__(self, message: str, command: str | None = None): |
| 11 | """ |
| 12 | Initialize command error. |
| 13 | |
| 14 | Args: |
| 15 | message: Error message |
| 16 | command: Command name that failed (optional) |
| 17 | """ |
| 18 | self.message = message |
| 19 | self.command = command |
| 20 | super().__init__(message) |
| 21 | |
| 22 | |
| 23 | class InvalidParameterError(CommandError): |