From 17d8751ec150f338e13ed19ef1ccce4e0f102b4d Mon Sep 17 00:00:00 2001 From: Jaime van Kessel Date: Wed, 7 Apr 2021 11:39:28 +0200 Subject: [PATCH] Fix incorrect typing in keyring attribute It didn't need Type["basemodel"] but a direct base model --- cura/OAuth2/KeyringAttribute.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cura/OAuth2/KeyringAttribute.py b/cura/OAuth2/KeyringAttribute.py index 47d5d5eb26..0ec9a08ce2 100644 --- a/cura/OAuth2/KeyringAttribute.py +++ b/cura/OAuth2/KeyringAttribute.py @@ -30,7 +30,7 @@ class KeyringAttribute: """ Descriptor for attributes that need to be stored in the keyring. With Fallback behaviour to the preference cfg file """ - def __get__(self, instance: Type["BaseModel"], owner: type) -> str: + def __get__(self, instance: BaseModel, owner: type) -> str: if self._store_secure: try: value = keyring.get_password("cura", self._keyring_name) @@ -42,7 +42,7 @@ class KeyringAttribute: else: return getattr(instance, self._name) - def __set__(self, instance: Type["BaseModel"], value: str): + def __set__(self, instance: BaseModel, value: str): if self._store_secure: setattr(instance, self._name, None) try: