From 44965f41dfaddc9d7d7eab86498fc25b65793db2 Mon Sep 17 00:00:00 2001 From: René 'Necoro' Neumann Date: Fri, 28 Mar 2008 15:01:29 +0100 Subject: Added version infos to exceptions --- portato/backend/catapult/system.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'portato/backend/catapult') diff --git a/portato/backend/catapult/system.py b/portato/backend/catapult/system.py index c04f997..8c84b56 100644 --- a/portato/backend/catapult/system.py +++ b/portato/backend/catapult/system.py @@ -32,6 +32,10 @@ class CatapultSystem (SystemInterface): so = self.bus.get_object(catapult.get_dbus_address(catapult.DEFAULT), catapult.CATAPULT_SYSTEM_BUS, follow_name_owner_changes = True) self.proxy = dbus.Interface(so, catapult.CATAPULT_SYSTEM_IFACE) + def get_version (self): + admint = dbus.Interface(self.bus.get_object(catapult.get_dbus_address(catapult.DEFAULT), catapult.CATAPULT_BUS), catapult.CATAPULT_ADMIN_IFACE) + return "Catapult: %s v. %s" % (self.proxy.bus_name.split(".")[-1], str(admint.version())) + def geneticize_list (self, list_of_packages, only_cpv = False): """Convertes a list of cpv's into L{backend.Package}s. -- cgit v1.2.3-70-g09d2