Changeset - f643ffc5d90b
[Not reviewed]
default
0 1 0
Dennis Fink - 10 years ago 2015-07-08 22:22:14

raise runtime error if default_json_file does not exists or is not a file
1 file changed with 6 insertions and 0 deletions:
0 comments (0 inline, 0 general)
spaceapi/active.py
Show inline comments
 
@@ -6,6 +6,12 @@ import os.path
 
default_json_file = os.path.abspath('default.json')
 
last_state_file = os.path.abspath('laststate.json')
 

	
 
if not os.path.exists(default_json_file):
 
    raise RuntimeError('default.json does not exists!')
 
elif not os.path.isfile(default_json_file):
 
    raise RuntimeError('defaul.json is not a file!')
 

	
 

	
 
default_json = {}
 
active_json = {}
 

	
0 comments (0 inline, 0 general)