Skip to content
Snippets Groups Projects
Commit e48b4c0b authored by Jonas Höppner's avatar Jonas Höppner
Browse files

package_release: Do not fail if a file does not exist

parent a5e27f6e
No related branches found
No related tags found
1 merge request!217package_release: Do not fail if a file does not exist
Pipeline #42908 passed with stage
in 15 minutes and 25 seconds
...@@ -28,7 +28,12 @@ def generate_md5sums_file(input_files: list[str], output_file: str): ...@@ -28,7 +28,12 @@ def generate_md5sums_file(input_files: list[str], output_file: str):
""" """
md5sums = {} md5sums = {}
for f in input_files: for f in input_files:
md5sums[os.path.basename(f)] = md5(f) # This might should be used somewhere before,
# but the previous state was not to fail when a file in
# the list did not exist, like in copy files
if os.path.exists(f):
md5sums[os.path.basename(f)] = md5(f)
output_dir = os.path.dirname(output_file) output_dir = os.path.dirname(output_file)
if output_dir: if output_dir:
os.makedirs(output_dir, exist_ok=True) os.makedirs(output_dir, exist_ok=True)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment