From 7496933554375a145654626199f17208d5ab3109 Mon Sep 17 00:00:00 2001 From: Dusty Mabe Date: Wed, 13 Nov 2024 12:02:30 -0500 Subject: [PATCH] cmd-osbuild: fix CI check failure on if conditional The check is invalid for this code because it's embedded python. Let's just workaround it for now by putting it in a elif so it won't match the string being looked for in https://github.com/coreos/coreos-assembler/blob/48fba72a62c739f6eaf4d7991052516fd574acc7/tests/check_one.sh#L30-L33 --- src/cmd-osbuild | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/cmd-osbuild b/src/cmd-osbuild index bc956a4bea..0e2377522f 100755 --- a/src/cmd-osbuild +++ b/src/cmd-osbuild @@ -61,7 +61,11 @@ j['images']['${artifact_name}'] = { 'sha256': '$(sha256sum_str < "${local_filepath}")', 'size': $(stat -c '%s' "${local_filepath}") } -if ${skip_compress}: +# backwards conditional here because of a invalid (for this code) CI check +# https://github.com/coreos/coreos-assembler/pull/3930#issuecomment-2473714222 +if False: + pass +elif ${skip_compress}: j['images']['${artifact_name}']['skip-compression'] = True json.dump(j, sys.stdout, indent=4) " > meta.json.new