From f20ce9c9566b00308af73bb3d0bfb3cc50e666ae Mon Sep 17 00:00:00 2001 From: Tim Lauridsen Date: Tue, 10 May 2016 11:09:36 +0200 Subject: [PATCH 1/4] workaround for dnf.Base.reset(sack=True) in hawkey 6.0.3 https://bugzilla.redhat.com/show_bug.cgi?id=1332067 --- python/dnfdaemon/server/__init__.py | 7 +++++-- python/dnfdaemon/server/backend.py | 1 + 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/python/dnfdaemon/server/__init__.py b/python/dnfdaemon/server/__init__.py index c220372..4a6078d 100644 --- a/python/dnfdaemon/server/__init__.py +++ b/python/dnfdaemon/server/__init__.py @@ -227,10 +227,13 @@ def search_with_attr(self, fields, keys, attrs, match_all, newest_only, def expire_cache(self): """Expire the dnf cache.""" - try: self.base.expire_cache() - self.base.reset(sack=True) + self.base.reset(sack=True, repos=True) + #FIXME: Workaround for dnf.Base.reset in hawkey 6.0.3 + # https://bugzilla.redhat.com/show_bug.cgi?id=1332067 + self.base.read_all_repos() + self.base.repos.all().set_progress_bar(self.base.md_progress) self.base.setup_base() return True except dnf.exceptions.RepoError as e: diff --git a/python/dnfdaemon/server/backend.py b/python/dnfdaemon/server/backend.py index dc224b3..7c3861f 100644 --- a/python/dnfdaemon/server/backend.py +++ b/python/dnfdaemon/server/backend.py @@ -64,6 +64,7 @@ def setup_base(self): """Setup dnf Sack and init packages helper""" logger.debug('setup DnfBase sack') self.fill_sack() + logger.debug('setup packages') self._packages = Packages(self) @property From 502a439df98d3c06fe7e6cba85a3725584265e34 Mon Sep 17 00:00:00 2001 From: Tim Lauridsen Date: Tue, 10 May 2016 16:55:14 +0200 Subject: [PATCH 2/4] Show all kernel packages as updates --- python/dnfdaemon/server/backend.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/python/dnfdaemon/server/backend.py b/python/dnfdaemon/server/backend.py index 7c3861f..ffc55fd 100644 --- a/python/dnfdaemon/server/backend.py +++ b/python/dnfdaemon/server/backend.py @@ -151,7 +151,7 @@ def updates(self): self._base.upgrade_all() self._base.resolve(allow_erasing=True) except dnf.exceptions.DepsolveError as e: - self.logger.debug(str(e)) + logger.debug(str(e)) return pkgs # return install/upgrade type pkgs from transaction for tsi in self._base.transaction: @@ -161,8 +161,7 @@ def updates(self): elif tsi.op_type == dnf.transaction.INSTALL: po = tsi.installed # action is INSTALL, then it should be a installonlypkg - if po.name in self._base.conf.installonlypkgs: - pkgs.append(po) + pkgs.append(po) return pkgs @property From c54c4a99c946262991577ba5eabb0365a376fe69 Mon Sep 17 00:00:00 2001 From: Tim Lauridsen Date: Tue, 10 May 2016 17:18:49 +0200 Subject: [PATCH 3/4] bumped version to 0.3.15 --- dnfdaemon.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dnfdaemon.spec b/dnfdaemon.spec index 1fb086e..8b78077 100644 --- a/dnfdaemon.spec +++ b/dnfdaemon.spec @@ -2,7 +2,7 @@ %global dnf_version 1.1.0 Name: dnfdaemon -Version: 0.3.14 +Version: 0.3.15 Release: 1%{?dist} Summary: DBus daemon for dnf package actions License: GPLv2+ @@ -99,6 +99,9 @@ fi %{python3_sitelib}/%{name}/client %changelog +* Tue May 10 2016 Tim Lauridsen 0.3.15-1 +- bumped release + * Fri Apr 29 2016 Tim Lauridsen 0.3.14-1 - bumped release From ab8eb328e87ae85b1f32bf1b1051ed948a4a3573 Mon Sep 17 00:00:00 2001 From: Tim Lauridsen Date: Tue, 10 May 2016 17:18:49 +0200 Subject: [PATCH 4/4] updated ChangeLog --- ChangeLog | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/ChangeLog b/ChangeLog index 3b80bb1..8e5def7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,27 @@ +2016-05-10 Tim Lauridsen + + * dnfdaemon.spec: bumped version to 0.3.15 + +2016-05-10 Tim Lauridsen + + * python/dnfdaemon/server/backend.py: Show all kernel packages as + updates + +2016-05-10 Tim Lauridsen + + * python/dnfdaemon/server/__init__.py, + python/dnfdaemon/server/backend.py: workaround for + dnf.Base.reset(sack=True) in hawkey 6.0.3 + https://bugzilla.redhat.com/show_bug.cgi?id=1332067 + +2016-04-29 Tim Lauridsen + + Merge branch 'release-0.3.14' into develop + +2016-04-29 Tim Lauridsen + + * ChangeLog: updated ChangeLog + 2016-04-29 Tim Lauridsen * dnfdaemon.spec: bumped version to 0.3.14