from typing import NamedTuple
[docs]class SideCarException(Exception):
"""Used to signal an general exception occurred during a particular
routine, the routine of which is specified by having a more specific exception class
derived from this one. The handler of the exception can then retrieve the original
general exception that was tagged along with the additional knowledge of when it occurred
"""
def __init__(self, exc: Exception) -> None: # pylint: disable=super-init-not-called
self.exc = exc
[docs]class PlaySpec(NamedTuple):
enabled: bool = True
filter_logs: bool = True
log_filter_pattern: str = ""
def __bool__(self) -> bool:
return self.enabled