From a22daf7b8a805213f0cbcbed2d689403dcce8534 Mon Sep 17 00:00:00 2001 From: Siegfried Weber Date: Wed, 6 Sep 2023 16:08:02 +0200 Subject: [PATCH 1/2] Deny unknown fields when deserializing ProductImageCustom and ProductImageStackableVersion --- src/commons/product_image_selection.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/commons/product_image_selection.rs b/src/commons/product_image_selection.rs index 654a29051..ed2a2587c 100644 --- a/src/commons/product_image_selection.rs +++ b/src/commons/product_image_selection.rs @@ -33,7 +33,7 @@ pub enum ProductImageSelection { } #[derive(Clone, Debug, Deserialize, Eq, JsonSchema, PartialEq, Serialize)] -#[serde(rename_all = "camelCase")] +#[serde(deny_unknown_fields, rename_all = "camelCase")] pub struct ProductImageCustom { /// Overwrite the docker image. /// Specify the full docker image name, e.g. `docker.stackable.tech/stackable/superset:1.4.1-stackable2.1.0` @@ -43,7 +43,7 @@ pub struct ProductImageCustom { } #[derive(Clone, Debug, Deserialize, Eq, JsonSchema, PartialEq, Serialize)] -#[serde(rename_all = "camelCase")] +#[serde(deny_unknown_fields, rename_all = "camelCase")] pub struct ProductImageStackableVersion { /// Version of the product, e.g. `1.4.1`. product_version: String, From 39b1cc6ae2eea35fe44d22404b4dd7af12c01869 Mon Sep 17 00:00:00 2001 From: Siegfried Weber Date: Wed, 6 Sep 2023 16:36:22 +0200 Subject: [PATCH 2/2] Update changelog --- CHANGELOG.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 72703f880..704c77e49 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,13 @@ All notable changes to this project will be documented in this file. ## [Unreleased] +### Fixed + +- Fix the error "data did not match any variant of untagged enum + ProductImageSelection" on OpenShift ([#646]). + +[#646]: https://github.com/stackabletech/operator-rs/pull/646 + ## [0.48.0] - 2023-08-18 ### Added