diff --git a/cura/OAuth2/KeyringAttribute.py b/cura/OAuth2/KeyringAttribute.py index 35ffdcbd24..58b45a67ef 100644 --- a/cura/OAuth2/KeyringAttribute.py +++ b/cura/OAuth2/KeyringAttribute.py @@ -5,7 +5,7 @@ from typing import Type, TYPE_CHECKING, Optional, List from io import BlockingIOError import keyring from keyring.backend import KeyringBackend -from keyring.errors import NoKeyringError, PasswordSetError, KeyringLocked +from keyring.errors import NoKeyringError, PasswordSetError, KeyringLocked, KeyringError from UM.Logger import Logger @@ -53,6 +53,10 @@ class KeyringAttribute: self._store_secure = False Logger.log("w", "The password retrieved from the keyring cannot be used because it contains characters that cannot be decoded.") return getattr(instance, self._name) + except KeyringError: + self._store_secure = False + Logger.logException("w", "Unknown keyring error.") + return getattr(instance, self._name) else: return getattr(instance, self._name)