diff --git a/authentik/stages/authenticator_mobile/models.py b/authentik/stages/authenticator_mobile/models.py index ba6e17770..5b8a105c1 100644 --- a/authentik/stages/authenticator_mobile/models.py +++ b/authentik/stages/authenticator_mobile/models.py @@ -11,6 +11,7 @@ from django.http import HttpRequest from django.utils.translation import gettext as __ from django.utils.translation import gettext_lazy as _ from django.views import View +from grpc import RpcError from rest_framework.serializers import BaseSerializer, Serializer from structlog.stdlib import get_logger @@ -196,7 +197,7 @@ class MobileTransaction(ExpiringModel): ) ) LOGGER.debug("Sent notification", id=response, tx_id=self.tx_id) - except ValueError as exc: + except (ValueError, RpcError) as exc: LOGGER.warning("failed to push", exc=exc, tx_id=self.tx_id) return True