Skip to content

Commit

Permalink
more changes
Browse files Browse the repository at this point in the history
  • Loading branch information
dansand committed May 16, 2024
1 parent 354a89f commit 485e0ae
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
5 changes: 3 additions & 2 deletions .github/scripts/parse_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ def validate_slug(proposed_slug):

#try a workaround for local tests
cmd = "python3 .github/scripts/generate_identifier.py"
if os.path.exists('../.github/scripts/generate_identifier.py'):
os.path.exists('../.github/scripts/generate_identifier.py')

#if os.path.exists('../.github/scripts/generate_identifier.py'):
# os.path.exists('../.github/scripts/generate_identifier.py')

try:
slug = subprocess.check_output(cmd, shell=True, text=True, stderr=open(os.devnull)).strip()
Expand Down
10 changes: 6 additions & 4 deletions .github/scripts/ro_crate_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -625,10 +625,12 @@ def defaults_and_customise_ro_crate(issue_dict, ro_crate, timestamp=False):
slug = ro_crate['@graph'][root_index]['alternateName']
ro_crate['@graph'][root_index]['url'] = [mate_science_url.format(slug), mate_gh_url.format(slug)]
thredds_string = MATE_THREDDS_BASE.format(slug)
roc_index = find_index_by_id(ro_crate, 'model_outputs')
ro_crate['@graph'][roc_index]['url'] = thredds_string
roc_index = find_index_by_id(ro_crate, 'model_inputs')
ro_crate['@graph'][roc_index]['url'] = thredds_string

#this maybe breaking something
#roc_index = find_index_by_id(ro_crate, 'model_outputs')
#ro_crate['@graph'][roc_index]['url'] = thredds_string
#roc_index = find_index_by_id(ro_crate, 'model_inputs')
#ro_crate['@graph'][roc_index]['url'] = thredds_string


#add date time as the date published ro-crate
Expand Down

0 comments on commit 485e0ae

Please sign in to comment.