diff --git a/python/dnfdaemon/client/__init__.py b/python/dnfdaemon/client/__init__.py index 21c10b9da8cf597ca05fcbee691ac1795c1f7b9d..e3c07f2db0abcd4564293ee67258830bfe75db5b 100644 --- a/python/dnfdaemon/client/__init__.py +++ b/python/dnfdaemon/client/__init__.py @@ -104,7 +104,7 @@ import re import weakref import logging -CLIENT_API_VERSION = 1 +CLIENT_API_VERSION = 2 logger = logging.getLogger("dnfdaemon.client") diff --git a/python/dnfdaemon/server/__init__.py b/python/dnfdaemon/server/__init__.py index 4f75220928682d053adb95f751ce5561286d0b2f..15b61af71bc0fbf5d6464ed4988499eb5277d560 100644 --- a/python/dnfdaemon/server/__init__.py +++ b/python/dnfdaemon/server/__init__.py @@ -44,7 +44,7 @@ import logging import operator import sys -API_VERSION = 1 # API Version must be bumped at API changes +API_VERSION = 2 # API Version must be bumped at API changes MAINLOOP = GLib.MainLoop() # Fake attributes, there is simulating real package attribute @@ -339,7 +339,7 @@ class DnfDaemonBase(dbus.service.Object, DownloadCallback): """ value = [] if pkg_filter in ['installed', 'available', 'updates', 'obsoletes', - 'recent', 'extras']: + 'recent', 'extras', 'updates_all']: pkgs = getattr(self.base.packages, pkg_filter) value = [self._get_po_list(po, attrs) for po in pkgs] return json.dumps(value) diff --git a/python/dnfdaemon/server/backend.py b/python/dnfdaemon/server/backend.py index 47aa10da45c168caa7418b7fcf9623bb10326bd0..dc224b34511aa11bd23668efe3d2a0582b488185 100644 --- a/python/dnfdaemon/server/backend.py +++ b/python/dnfdaemon/server/backend.py @@ -164,6 +164,10 @@ class Packages: pkgs.append(po) return pkgs + @property + def updates_all(self): + return self.query.upgrades().latest().run() + @property def all(self): """Get all packages installed and available.