Skip to content

Commit a2ced52

Browse files
Midnightersimonbray
authored andcommitted
fix: place bioconductor images at the end
1 parent f2512b4 commit a2ced52

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

get_container_list.py

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -288,16 +288,23 @@ def get_new_images(
288288
) -> List[str]:
289289
"""Identify new images from the given lists."""
290290
denylist = tuple(denylist)
291-
result = sorted(frozenset(quay_images) - frozenset(singularity_images))
292-
log_images(log_file=log_file, images=result)
291+
diff = sorted(frozenset(quay_images) - frozenset(singularity_images))
292+
log_images(log_file=log_file, images=diff)
293293
# Filter new images using the deny list.
294-
# FIXME: Is it necessary to sort bioconductor images to the end as before?
295-
return sorted(
294+
result = sorted(
296295
filter(
297296
lambda image: not any(image.startswith(entry) for entry in denylist),
298-
result,
297+
diff,
299298
)
300299
)
300+
others = []
301+
bioconductor = []
302+
for img in diff:
303+
if img.startswith("bioconductor"):
304+
bioconductor.append(img)
305+
else:
306+
others.append(img)
307+
return others + bioconductor
301308

302309

303310
def parse_denylist(filename: Path) -> List[str]:

0 commit comments

Comments
 (0)