Skip to content

Commit 96e1f5b

Browse files
committed
Use ValueError instead of ImportError to catch exception when importing GIR bindings
When importing specific version of GIR bindings, the ValueError exception is raised instead of ImportError. This should make libsecret optional as intended Fixes: #94
1 parent f291161 commit 96e1f5b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

jobviewer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
gi.require_version('Secret', '1')
5858
from gi.repository import Secret
5959
USE_SECRET=True
60-
except ImportError:
60+
except ValueError:
6161
USE_SECRET=False
6262

6363
import gettext

0 commit comments

Comments
 (0)