Defining an exception here is a bit problematic, cause you cannot properly catch it, if it was raised in a different mgr module.
| 35 | |
| 36 | |
| 37 | class SpecValidationError(Exception): |
| 38 | """ |
| 39 | Defining an exception here is a bit problematic, cause you cannot properly catch it, |
| 40 | if it was raised in a different mgr module. |
| 41 | """ |
| 42 | def __init__(self, |
| 43 | msg: str, |
| 44 | errno: int = -errno.EINVAL): |
| 45 | super(SpecValidationError, self).__init__(msg) |
| 46 | self.errno = errno |
| 47 | |
| 48 | |
| 49 | class HostSpec(object): |
no outgoing calls
no test coverage detected