hopefully some better error handling
This commit is contained in:
parent
f2b3396b0d
commit
91b357a68e
3
main.py
3
main.py
@ -58,6 +58,7 @@ def get_everything(manifest_path, early_cutoff):
|
|||||||
vcs_path = config['Upstream_VCS']
|
vcs_path = config['Upstream_VCS']
|
||||||
print("------------------")
|
print("------------------")
|
||||||
#print(vcs_path)
|
#print(vcs_path)
|
||||||
|
try:
|
||||||
repo_path = vcs_path[0]
|
repo_path = vcs_path[0]
|
||||||
largest_object[repo_path] = {}
|
largest_object[repo_path] = {}
|
||||||
largest_object[repo_path]["perceval_obj"] = pt.main(vcs_path, early_cutoff)
|
largest_object[repo_path]["perceval_obj"] = pt.main(vcs_path, early_cutoff)
|
||||||
@ -86,6 +87,8 @@ def get_everything(manifest_path, early_cutoff):
|
|||||||
repo_uri_list = repo_path.split('/')
|
repo_uri_list = repo_path.split('/')
|
||||||
with open('/data/users/mgaughan/kkex_data_110723/' + repo_uri_list[-2] + '_' + repo_uri_list[-1] + '_result.json', 'w') as data_path:
|
with open('/data/users/mgaughan/kkex_data_110723/' + repo_uri_list[-2] + '_' + repo_uri_list[-1] + '_result.json', 'w') as data_path:
|
||||||
json.dump(largest_object[repo_path], data_path)
|
json.dump(largest_object[repo_path], data_path)
|
||||||
|
except:
|
||||||
|
print("miscellanea error in the main body")
|
||||||
except yaml.YAMLError as err:
|
except yaml.YAMLError as err:
|
||||||
print(err)
|
print(err)
|
||||||
print("----------------------")
|
print("----------------------")
|
||||||
|
Loading…
Reference in New Issue
Block a user