Sfoglia il codice sorgente

Check if cryptography is installed

Oz N Tiram 8 anni fa
parent
commit
a37812c73a
1 ha cambiato i file con 7 aggiunte e 0 eliminazioni
  1. 7 0
      pwman/__init__.py

+ 7 - 0
pwman/__init__.py

@@ -26,6 +26,13 @@ import pkg_resources
 from pwman.util import config
 from pwman.data.factory import check_db_version
 
+try:
+    import cryptography
+    has_cryptography = True
+except ImportError:
+    has_cryptography = False
+
+
 appname = "pwman3"
 
 try: