Fix empty dunikey

This commit is contained in:
poka 2020-11-18 07:34:02 +01:00
parent fc53bcbfcc
commit b21179c5a1
2 changed files with 4 additions and 0 deletions

View File

@ -6,6 +6,8 @@ if not os.path.isfile("userEnv.py"):
copyfile("userEnv.py.template", "userEnv.py")
try:
from userEnv import dunikey, pod
if dunikey == "":
raise ValueError("Dunikey is empty")
except:
sys.stderr.write("Please fill the path to your private key (PubSec), and a Cesium ES address in userEnv.py\n")
sys.exit(1)

View File

@ -11,6 +11,8 @@ class ReadFromCesium:
# Get my pubkey from my private key
try:
self.dunikey = dunikey
if dunikey == "":
raise ValueError("Dunikey is empty")
except:
sys.stderr.write("Please fill the path to your private key (PubSec)\n")
sys.exit(1)