From 8a243528772b155923c462b926d68e4399b8e81f Mon Sep 17 00:00:00 2001 From: majianhan Date: Mon, 17 Nov 2025 05:19:21 +0000 Subject: [PATCH] dnf: Remove verify_tsi_package callback parameter dnf: Fix test typo --- backport-fix-typo-test.patch | 35 +++++++++++++++++++++++++++++++++++ backport-verify-package.patch | 28 ++++++++++++++++++++++++++++ dnf.spec | 10 +++++++++- 3 files changed, 72 insertions(+), 1 deletion(-) create mode 100644 backport-fix-typo-test.patch create mode 100644 backport-verify-package.patch diff --git a/backport-fix-typo-test.patch b/backport-fix-typo-test.patch new file mode 100644 index 0000000..750eda8 --- /dev/null +++ b/backport-fix-typo-test.patch @@ -0,0 +1,35 @@ +Subject: [PATCH 05/30] Fix typo in test file + +--- + tests/test_fill_sack_from_repos_in_cache.py | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/tests/test_fill_sack_from_repos_in_cache.py b/tests/test_fill_sack_from_repos_in_cache.py +index 30d02cfe61..5f37fe7266 100644 +--- a/tests/test_fill_sack_from_repos_in_cache.py ++++ b/tests/test_fill_sack_from_repos_in_cache.py +@@ -213,7 +213,7 @@ def test_exception_with_checksum_mismatch_and_only_repomd(self): + self.assertRaises(dnf.exceptions.RepoError, + self.test_base.fill_sack_from_repos_in_cache, load_system_repo=False) + +- def test_checksum_mistmatch_regenerates_solv(self): ++ def test_checksum_mismatch_regenerates_solv(self): + self._setUp_from_repo_path(os.path.join(os.path.abspath(os.path.dirname(__file__)), "repos/rpm")) + self._create_cache_for_repo(os.path.join(os.path.abspath(os.path.dirname(__file__)), "repos/drpm"), + self.tmpdir, "drpm-repo") +@@ -223,7 +223,7 @@ def test_checksum_mistmatch_regenerates_solv(self): + os.path.join(self.tmpdir, "cache/test-repo.solv")) + + # Now we only have cache with solvx, mismatching solv file and xml metadata. +- # Checksum mistmatch causes regeneration of solv file and repo works. ++ # Checksum mismatch causes regeneration of solv file and repo works. + + self.test_base.fill_sack_from_repos_in_cache(load_system_repo=False) + + +From 49feb2253d2376d154a5ff5bfb58ec65c2072b63 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= +Date: Tue, 14 Nov 2023 12:30:06 +0100 +Subject: [PATCH 06/30] DNS key verification: Fix parsing an armored PGP key + +A PGP armor message can contain any amount of headers. Up to Fedora 38 diff --git a/backport-verify-package.patch b/backport-verify-package.patch new file mode 100644 index 0000000..caee613 --- /dev/null +++ b/backport-verify-package.patch @@ -0,0 +1,28 @@ +Subject: [PATCH 01/16] Does not print Verify: package (RhBug:1908253) + +It was replace by RPM transaction item return code and it only prints +a message to terminal. It was not remove to keep compatibility of +outputs, but it does nothing. + +https://bugzilla.redhat.com/show_bug.cgi?id=1908253 +--- + + dnf/base.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/dnf/base.py b/dnf/base.py +index b0c7565..9fd73c1 100644 +--- a/dnf/base.py ++++ b/dnf/base.py +@@ -1176,7 +1176,7 @@ class Base(object): + logger.log(dnf.logging.DDEBUG, 'RPM transaction TsFlag is %s' % self._ts.isTsFlagSet(rpm.RPMTRANS_FLAG_TEST)) + # sync up what just happened versus what is in the rpmdb + if not self._ts.isTsFlagSet(rpm.RPMTRANS_FLAG_TEST): +- self._verify_transaction(cb.verify_tsi_package) ++ self._verify_transaction() + + return tid + +-- +2.43.0 + diff --git a/dnf.spec b/dnf.spec index abf2dc2..d72d6b7 100644 --- a/dnf.spec +++ b/dnf.spec @@ -3,7 +3,7 @@ Name: dnf Version: 4.16.2 -Release: 8 +Release: 9 Summary: A software package manager that manages packages on Linux distributions. License: GPL-2.0-or-later AND GPL-1.0-only URL: https://github.com/rpm-software-management/dnf @@ -34,6 +34,8 @@ Patch6008: backport-Update-the-man-page-entry-for-the-countme-option. Patch6009: backport-Allow-local-downloads-to-same-downloaddir.patch Patch9001: bugfix-automatic-Use-add_security_filters-not-_update_secur.patch +Patch9007: backport-verify-package.patch +Patch9008: backport-fix-typo-test.patch BuildArch: noarch BuildRequires: cmake gettext systemd bash-completion python3-sphinx @@ -261,6 +263,12 @@ popd %{_mandir}/man8/%{name}-automatic.8* %changelog +* Sun Nov 17 2024 majianhan - 4.16.2-9 +- Type:bugfix +- ID:RhBug:1908253 +- SUG:NA +- DESC: Remove verify_tsi_package callback as it was replaced by RPM transaction return code + * Mon Nov 04 2024 majianhan - 4.16.2-8 - Type:bugfix - ID:NA -- Gitee