Skip to content

Commit df56a59

Browse files
committed
Allow S3 metadata key published_image_metadata to be undefined
Related: #189 Signed-off-by: Tobias Wolf <wolf@b1-systems.de> On-behalf-of: SAP <tobias.wolf@sap.com>
1 parent e682361 commit df56a59

File tree

8 files changed

+9
-8
lines changed

8 files changed

+9
-8
lines changed

.github/actions/setup/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Installs the given GardenLinux Python library
44
inputs:
55
version:
66
description: GardenLinux Python library version
7-
default: "0.10.14"
7+
default: "0.10.15"
88
python_version:
99
description: Python version to setup
1010
default: "3.13"

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "gardenlinux"
3-
version = "0.10.14"
3+
version = "0.10.15"
44
description = "Contains tools to work with the features directory of gardenlinux, for example deducting dependencies from feature sets or validating cnames"
55
authors = ["Garden Linux Maintainers <contact@gardenlinux.io>"]
66
license = "Apache-2.0"

src/gardenlinux/github/release_notes/deployment_platform/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ def full_name(self) -> str:
1515
def published_images_by_regions(
1616
self, image_metadata: Dict[str, Any]
1717
) -> Dict[str, Any]:
18-
published_image_metadata = image_metadata["published_image_metadata"]
18+
published_image_metadata = image_metadata.get("published_image_metadata")
1919
flavor_name = image_metadata["s3_key"].split("/")[-1]
2020

2121
regions = []

src/gardenlinux/github/release_notes/deployment_platform/amazon_web_services.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def full_name(self) -> str:
1313
def published_images_by_regions(
1414
self, image_metadata: Dict[str, Any]
1515
) -> Dict[str, Any]:
16-
published_image_metadata = image_metadata["published_image_metadata"]
16+
published_image_metadata = image_metadata.get("published_image_metadata")
1717
flavor_name = image_metadata["s3_key"].split("/")[-1]
1818

1919
regions = []

src/gardenlinux/github/release_notes/deployment_platform/azure.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def image_extension(self) -> str:
1616
def published_images_by_regions(
1717
self, image_metadata: Dict[str, Any]
1818
) -> Dict[str, Any]:
19-
published_image_metadata = image_metadata["published_image_metadata"]
19+
published_image_metadata = image_metadata.get("published_image_metadata")
2020
flavor_name = image_metadata["s3_key"].split("/")[-1]
2121

2222
gallery_images = []

src/gardenlinux/github/release_notes/deployment_platform/google_cloud.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def image_extension(self) -> str:
1717
def published_images_by_regions(
1818
self, image_metadata: Dict[str, Any]
1919
) -> Dict[str, Any]:
20-
published_image_metadata = image_metadata["published_image_metadata"]
20+
published_image_metadata = image_metadata.get("published_image_metadata")
2121
flavor_name = image_metadata["s3_key"].split("/")[-1]
2222

2323
details = {}

src/gardenlinux/github/release_notes/deployment_platform/openstack.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def full_name(self) -> str:
1414
def published_images_by_regions(
1515
self, image_metadata: Dict[str, Any]
1616
) -> Dict[str, Any]:
17-
published_image_metadata = image_metadata["published_image_metadata"]
17+
published_image_metadata = image_metadata.get("published_image_metadata")
1818
flavor_name = image_metadata["s3_key"].split("/")[-1]
1919

2020
regions = []

src/gardenlinux/github/release_notes/sections.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,8 @@ def release_notes_image_ids_section(metadata_files: list[str]) -> str:
262262
with open(metadata_file_path) as f:
263263
metadata = yaml.load(f, Loader=SafeLoader)
264264

265-
published_image_metadata = metadata["published_image_metadata"]
265+
published_image_metadata = metadata.get("published_image_metadata")
266+
266267
# Skip if no publishing metadata found
267268
if published_image_metadata is None:
268269
continue

0 commit comments

Comments
 (0)