authentik.policies.exceptions

policy exceptions

 1"""policy exceptions"""
 2
 3from authentik.lib.sentry import SentryIgnoredException
 4
 5
 6class PolicyEngineException(SentryIgnoredException):
 7    """Error raised when a policy engine is configured incorrectly"""
 8
 9
10class PolicyException(SentryIgnoredException):
11    """Exception that should be raised during Policy Evaluation, and can be recovered from."""
12
13    src_exc: Exception | None = None
14
15    def __init__(self, src_exc: Exception | None = None) -> None:
16        super().__init__()
17        self.src_exc = src_exc
class PolicyEngineException(authentik.lib.sentry.SentryIgnoredException):
7class PolicyEngineException(SentryIgnoredException):
8    """Error raised when a policy engine is configured incorrectly"""

Error raised when a policy engine is configured incorrectly

class PolicyException(authentik.lib.sentry.SentryIgnoredException):
11class PolicyException(SentryIgnoredException):
12    """Exception that should be raised during Policy Evaluation, and can be recovered from."""
13
14    src_exc: Exception | None = None
15
16    def __init__(self, src_exc: Exception | None = None) -> None:
17        super().__init__()
18        self.src_exc = src_exc

Exception that should be raised during Policy Evaluation, and can be recovered from.

PolicyException(src_exc: Exception | None = None)
16    def __init__(self, src_exc: Exception | None = None) -> None:
17        super().__init__()
18        self.src_exc = src_exc
src_exc: Exception | None = None