import dnf-plugins-core-4.0.24-3.el9

This commit is contained in:
CentOS Sources 2022-03-01 08:06:36 -05:00 committed by Stepan Oksanichenko
parent 23c298f98c
commit 6e59ffdaa9
2 changed files with 39 additions and 2 deletions

View File

@ -0,0 +1,33 @@
From 66bac802e84fcf97dbe32690c33c420cb8f16891 Mon Sep 17 00:00:00 2001
From: Jaroslav Rohel <jrohel@redhat.com>
Date: Fri, 4 Feb 2022 10:28:59 +0100
Subject: [PATCH] plugin debug: Use base._ts.dbCookie() to determining rpmdb
version
The debug plugin used `base.sack._rpmdb_version()` method. Which is
actually the private method `hawkey.Sack._rpmdb_version()` from libdnf.
The patch uses the `base._ts.dbCookie()` method. This method was added
to DNF 4.11.0. And internally it calls the new official API function
`rpm.TransactionSet.dbCookie()` from librpm. This is a necessary step
to allow the `._rpmdb_version()` method to be removed from libdnf.
---
plugins/debug.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/plugins/debug.py b/plugins/debug.py
index ad136a9..c443f71 100644
--- a/plugins/debug.py
+++ b/plugins/debug.py
@@ -161,7 +161,7 @@ class DebugDumpCommand(dnf.cli.Command):
def dump_rpmdb_versions(self):
self.write("%%%%RPMDB VERSIONS\n")
- version = self.base.sack._rpmdb_version()
+ version = self.base._ts.dbCookie()
self.write(" all: %s\n" % version)
return
--
2.34.1

View File

@ -1,4 +1,4 @@
%{?!dnf_lowest_compatible: %global dnf_lowest_compatible 4.2.22}
%{?!dnf_lowest_compatible: %global dnf_lowest_compatible 4.10.0-4}
%global dnf_plugins_extra 2.0.0
%global hawkey_version 0.46.1
%global yum_utils_subpackage_name dnf-utils
@ -34,7 +34,7 @@
Name: dnf-plugins-core
Version: 4.0.24
Release: 2%{?dist}
Release: 3%{?dist}
Summary: Core Plugins for DNF
License: GPLv2+
URL: https://github.com/rpm-software-management/dnf-plugins-core
@ -42,6 +42,7 @@ Source0: %{url}/archive/%{version}/%{name}-%{version}.tar.gz
Patch1: 0001-groups-manager-More-benevolent-resolving-of-packages-RhBug2013633.patch
Patch2: 0002-versionlock-fix-multi-pkg-lock-RhBug2013324.patch
Patch3: 0003-Update-documentation-for-adding-specific-version-RhBug2013332.patch
Patch4: 0004-plugin-debug-Use-base._ts.dbCookie-to-determining-rp.patch
BuildArch: noarch
BuildRequires: cmake
@ -768,6 +769,9 @@ ln -sf %{_mandir}/man1/%{yum_utils_subpackage_name}.1.gz %{buildroot}%{_mandir}/
%endif
%changelog
* Mon Feb 07 2022 Pavla Kratochvilova <pkratoch@redhat.com> - 4.0.24-3
- Backport patch with new way to determine rpmdb version
* Thu Dec 09 2021 Pavla Kratochvilova <pkratoch@redhat.com> - 4.0.24-2
- [groups-manager] Use full NEVRA for matching packages instead of only name (RhBug:2029864)
- [versionlock] Fix: Multiple package-name-spec arguments don't lock (RhBug:2029871)