From caae869f06491925b6af005aaa856111316da34d Mon Sep 17 00:00:00 2001 From: Martin Jediny Date: Fri, 13 Dec 2024 10:54:14 +0100 Subject: [PATCH] feat: change image data field Since this script won't use the advisory data anymore, the SBOM data can be simplified. Signed-off-by: Martin Jediny --- sbom/update_component_sbom.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sbom/update_component_sbom.py b/sbom/update_component_sbom.py index 71d507c..8df4149 100755 --- a/sbom/update_component_sbom.py +++ b/sbom/update_component_sbom.py @@ -140,9 +140,7 @@ def update_sboms(data_path: str, input_path: str, output_path: str) -> None: with open(data_path, "r") as data_file: data = json.load(data_file) - component_to_purls_map = get_component_to_purls_map( - data["releaseNotes"]["content"].get("images", []) - ) + component_to_purls_map = get_component_to_purls_map(data.get("images", [])) # get all json files in input dir input_jsons = glob.glob(os.path.join(input_path, "*.json")) # loop through files