aboutsummaryrefslogtreecommitdiff
path: root/jwstdp
diff options
context:
space:
mode:
authorMatt Rendina <rendinam@users.noreply.github.com>2019-11-18 14:54:12 -0500
committerGitHub <noreply@github.com>2019-11-18 14:54:12 -0500
commit4938db967cd03ac9e40e7764269717025dc9af2d (patch)
tree8c01462f5a589300284a19d067fe37df6598a19a /jwstdp
parent33fde33643cec5633e5efbcd6b060bb3e96f6957 (diff)
downloadastroconda-releases-4938db967cd03ac9e40e7764269717025dc9af2d.tar.gz
Correct prefix list availability (#102)
Diffstat (limited to 'jwstdp')
-rwxr-xr-xjwstdp/utils/jwst_delivery_prep8
1 files changed, 5 insertions, 3 deletions
diff --git a/jwstdp/utils/jwst_delivery_prep b/jwstdp/utils/jwst_delivery_prep
index 6fe869b..742adec 100755
--- a/jwstdp/utils/jwst_delivery_prep
+++ b/jwstdp/utils/jwst_delivery_prep
@@ -29,7 +29,7 @@ def modify_dep(line, text):
return(line)
-def get_artifact_names(url):
+def get_artifact_names(url, prefixes):
'''Retrieve list of all available artifacts in the target artifactory
repository.'''
names = []
@@ -38,7 +38,7 @@ def get_artifact_names(url):
payload = result.readlines()
for line in payload:
line = str(line.decode())
- for prefix in artifact_prefixes:
+ for prefix in prefixes:
if prefix in line:
mat = re.search('(?<=").*(?=\")', line)
names.append(mat.group(0))
@@ -161,7 +161,9 @@ def main():
config_map = []
from collections import namedtuple
confset = namedtuple('confset', ['config', 'os'])
- artifacts = get_artifact_names(f'{art_url_base}/{art_repo}')
+ artifacts = get_artifact_names(
+ f'{art_url_base}/{art_repo}',
+ artifact_prefixes)
# Download only the available artifacts that correspond to the
# requested build name into new release dir.