disable keyrings without warnings in pyflakes (refs #706)
This commit is contained in:
parent
8bf985ad86
commit
2421aa9d78
1 changed files with 4 additions and 4 deletions
|
|
@ -104,8 +104,8 @@ class ValueBackendPassword(Value):
|
|||
return
|
||||
|
||||
try:
|
||||
# See #706
|
||||
import keyring_DISABLED
|
||||
raise ImportError('Keyrings are disabled (see #706)')
|
||||
import keyring
|
||||
keyring.set_password(self._domain, self.id, passwd)
|
||||
except Exception:
|
||||
self._value = passwd
|
||||
|
|
@ -123,8 +123,8 @@ class ValueBackendPassword(Value):
|
|||
return self._value
|
||||
|
||||
try:
|
||||
# See #706
|
||||
import keyring_DISABLED
|
||||
raise ImportError('Keyrings are disabled (see #706)')
|
||||
import keyring
|
||||
except ImportError:
|
||||
passwd = None
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue