Commit 6de55dbd authored by Lachlan's avatar Lachlan

Check if version if valid before trying to remove image

parent 0c031b6a
Pipeline #71533758 failed with stages
in 1 minute and 23 seconds
......@@ -603,7 +603,8 @@ def run(config_files, _debug, keep_images, reuse_images, output_file):
if not keep_images and not reuse_images:
logging.info("Deleting test-specific Docker images")
for version in versions_dict.values():
docker_client.images.remove(version.image.id)
if version:
docker_client.images.remove(version.image.id)
for cont in container_set:
subprocess.run(["docker", "rm", str(cont)])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment