* Mon Nov 11 2024 Miroslav Rezanina <mrezanin@redhat.com> - 24.1.4-20

- ci-Remove-python3-jsonschema-dependency.patch [RHEL-65849]
- Resolves: RHEL-65849
  ([RHEL-10] Drop cloud-init dependency on python-jsonschema)
This commit is contained in:
Miroslav Rezanina 2024-11-11 07:46:19 -05:00
parent 59b57283a0
commit c16601a337
2 changed files with 62 additions and 2 deletions

View File

@ -0,0 +1,54 @@
From bb5f9a5e4ad5225ce9f380812a9ec04828702e76 Mon Sep 17 00:00:00 2001
From: Ani Sinha <anisinha@redhat.com>
Date: Tue, 22 Oct 2024 11:49:47 +0530
Subject: [PATCH] Remove python3-jsonschema dependency
RH-Author: Ani Sinha <anisinha@redhat.com>
RH-MergeRequest: 115: Remove python3-jsonschema dependency
RH-Jira: RHEL-65849
RH-Acked-by: Vitaly Kuznetsov <vkuznets@redhat.com>
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
RH-Commit: [1/1] b2c16e5e07d12eeb05a6d86ccb5e988220afafa3 (anisinha/cloud-init)
Cloud-init is the only package in RHEL-10 that still needs it. It is used by the
schema validator. When python3-jsonschema is not present, the schema validator
does not run and fails gracefully with the log message:
schema.py[DEBUG]: Ignoring schema validation. jsonschema is not present
There seems to be no other major regressions if we remove the dependency.
Please see RHEL-61183 for test cases and test results.
Removing the dependency enables us to not support jsonschema package for
the lifetime of RHEL-10 release.
python3-jsonschema can be replaced with fastjsonschema but the replacement is
not trivial and upstream has not committed to doing the work yet. When
support for fastjsonschema is implemented, we will incorporate the fix either
through backport or a rebase and then the schema validator will hopefully
be enabled again.
Remove the dependency from the spec file and requirements.txt file. This
change is downstream only for now.
X-downstream-only: true
Signed-off-by: Ani Sinha <anisinha@redhat.com>
---
.distro/cloud-init.spec | 1 -
requirements.txt | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/requirements.txt b/requirements.txt
index eabd7a22..84211e80 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -28,4 +28,4 @@ requests
jsonpatch
# For validating cloud-config sections per schema definitions
-jsonschema
+# jsonschema
--
2.39.3

View File

@ -6,7 +6,7 @@
Name: cloud-init Name: cloud-init
Version: 24.1.4 Version: 24.1.4
Release: 19%{?dist} Release: 20%{?dist}
Summary: Cloud instance init scripts Summary: Cloud instance init scripts
License: Apache-2.0 OR GPL-3.0-only License: Apache-2.0 OR GPL-3.0-only
URL: https://github.com/canonical/cloud-init URL: https://github.com/canonical/cloud-init
@ -63,6 +63,8 @@ Patch26: ci-Fix-metric-setting-for-ifcfg-network-connections-for.patch
Patch27: ci-fix-Render-bridges-correctly-for-v2-on-sysconfig-wit.patch Patch27: ci-fix-Render-bridges-correctly-for-v2-on-sysconfig-wit.patch
# For RHEL-65019 - NoCloud - network_config bridges incorrectly configured [rhel-10] # For RHEL-65019 - NoCloud - network_config bridges incorrectly configured [rhel-10]
Patch28: ci-fix-Render-v2-bridges-correctly-on-network-manager-w.patch Patch28: ci-fix-Render-v2-bridges-correctly-on-network-manager-w.patch
# For RHEL-65849 - [RHEL-10] Drop cloud-init dependency on python-jsonschema
Patch29: ci-Remove-python3-jsonschema-dependency.patch
BuildArch: noarch BuildArch: noarch
@ -98,7 +100,6 @@ Requires: procps
Requires: python3-configobj Requires: python3-configobj
Requires: python3-jinja2 Requires: python3-jinja2
Requires: python3-jsonpatch Requires: python3-jsonpatch
Requires: python3-jsonschema
Requires: python3-oauthlib Requires: python3-oauthlib
Requires: python3-pyserial Requires: python3-pyserial
Requires: python3-PyYAML Requires: python3-PyYAML
@ -273,6 +274,11 @@ fi
%changelog %changelog
* Mon Nov 11 2024 Miroslav Rezanina <mrezanin@redhat.com> - 24.1.4-20
- ci-Remove-python3-jsonschema-dependency.patch [RHEL-65849]
- Resolves: RHEL-65849
([RHEL-10] Drop cloud-init dependency on python-jsonschema)
* Tue Nov 05 2024 Miroslav Rezanina <mrezanin@redhat.com> - 24.1.4-19 * Tue Nov 05 2024 Miroslav Rezanina <mrezanin@redhat.com> - 24.1.4-19
- ci-Fix-metric-setting-for-ifcfg-network-connections-for.patch [RHEL-65016] - ci-Fix-metric-setting-for-ifcfg-network-connections-for.patch [RHEL-65016]
- ci-fix-Render-bridges-correctly-for-v2-on-sysconfig-wit.patch [RHEL-65019] - ci-fix-Render-bridges-correctly-for-v2-on-sysconfig-wit.patch [RHEL-65019]