Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/cura
diff options
context:
space:
mode:
authorGhostkeeper <rubend@tutanota.com>2021-11-30 15:27:32 +0300
committerGhostkeeper <rubend@tutanota.com>2021-11-30 15:27:32 +0300
commit5da63fda26f153a3af149abb405b7856b356bf7b (patch)
tree6ee49c4ff62b94dec7cc64a6bfa788937508770c /cura
parent2f999ca399cad441f104b6d35f2c0691aafb5d79 (diff)
Also catch BlockingIOError when getting a keyring attribute
This occurs when there's a timeout, on some systems, when asking for the password to the keyring. We'll interpret a timeout as a refusal to enter a password. Fixes Sentry issue CURA-332.
Diffstat (limited to 'cura')
-rw-r--r--cura/OAuth2/KeyringAttribute.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/cura/OAuth2/KeyringAttribute.py b/cura/OAuth2/KeyringAttribute.py
index a8c60de994..35ffdcbd24 100644
--- a/cura/OAuth2/KeyringAttribute.py
+++ b/cura/OAuth2/KeyringAttribute.py
@@ -2,6 +2,7 @@
# Cura is released under the terms of the LGPLv3 or higher.
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
@@ -44,7 +45,7 @@ class KeyringAttribute:
self._store_secure = False
Logger.logException("w", "No keyring backend present")
return getattr(instance, self._name)
- except KeyringLocked:
+ except (KeyringLocked, BlockingIOError):
self._store_secure = False
Logger.log("i", "Access to the keyring was denied.")
return getattr(instance, self._name)