From 6f705cac637853389703943239d9073994f79b40 Mon Sep 17 00:00:00 2001 From: Guido Günther Date: Mon, 29 Dec 2014 12:04:10 +0100 Subject: Add mapping for libvirt-daemon -> libvirtd Needed for the sysv init based systems --- whatmaps/debiandistro.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/whatmaps/debiandistro.py b/whatmaps/debiandistro.py index 3a3bf16..2a095d1 100644 --- a/whatmaps/debiandistro.py +++ b/whatmaps/debiandistro.py @@ -47,9 +47,10 @@ class DebianDistro(Distro): 'dovecot-pop3d': [ 'dovecot' ], 'exim4-daemon-light': [ 'exim4' ], 'exim4-daemon-heavy': [ 'exim4' ], - 'qemu-system-x86_64': [ 'libvirt-guests' ], + 'libvirt-daemon': [ 'libvirtd' ], 'openjdk-6-jre-headless': ['jenkins', 'tomcat7'], 'openjdk-7-jre-headless': ['jenkins', 'tomcat7'], + 'qemu-system-x86_64': [ 'libvirt-guests' ], } # Per package blacklist -- cgit v1.2.3 From 2f0e5828e7c24b0776313f4bf4628126ccb307c2 Mon Sep 17 00:00:00 2001 From: Guido Günther Date: Thu, 28 May 2015 08:42:04 +0200 Subject: Silence output if package list is empty --- whatmaps/command.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/whatmaps/command.py b/whatmaps/command.py index d0f5c3e..c39b06d 100755 --- a/whatmaps/command.py +++ b/whatmaps/command.py @@ -81,7 +81,8 @@ def find_pkgs(procs, distro): pkg.procs = [ proc ] pkgs[pkg.name] = pkg - logging.info("Packages that ship the affected binaries:") + if pkgs: + logging.info("Packages that ship the affected binaries:") for pkg in pkgs.values(): logging.info(" Pkg: %s, binaries: %s" % (pkg.name, pkg.procs)) -- cgit v1.2.3 From 7172ce231f4cef66465a4384399460e00b717d41 Mon Sep 17 00:00:00 2001 From: Guido Günther Date: Mon, 29 Jun 2015 14:46:34 +0200 Subject: Don't print overly long error message In the systemd case So far we dumped the whole output of the status command. Only dump the pats we actually looked at. --- whatmaps/systemd.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/whatmaps/systemd.py b/whatmaps/systemd.py index 3407128..ef15a26 100644 --- a/whatmaps/systemd.py +++ b/whatmaps/systemd.py @@ -1,6 +1,6 @@ # vim: set fileencoding=utf-8 : # -# (C) 2014 Guido Günther +# (C) 2014,2015 Guido Günther # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or @@ -44,4 +44,4 @@ class Systemd(object): elif parts[1].endswith('.service'): return parts[1] else: - raise ValueError("Can't parse service name from\n%s" % output) + raise ValueError("Can't parse service name from: (%s %s)" % (parts[0], parts[1])) -- cgit v1.2.3 From 57006507c68b99c5e9ee6dcfb526aaae02f1e9b8 Mon Sep 17 00:00:00 2001 From: Guido Günther Date: Mon, 29 Jun 2015 15:19:17 +0200 Subject: Fix assertRaises invocations We had the arguments reversed Closes: #790372 --- tests/test_distro.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test_distro.py b/tests/test_distro.py index 88fa984..409c1c6 100644 --- a/tests/test_distro.py +++ b/tests/test_distro.py @@ -36,10 +36,10 @@ class TestDistro(unittest.TestCase): self.assertEqual(Distro.service_blacklist, set()) self.assertIsNone(Distro.id) # Pure virtual methods - self.assertRaises(Distro.pkg, None, None, NotImplementedError) - self.assertRaises(Distro.pkg_by_file, None, NotImplementedError) - self.assertRaises(Distro.restart_service_cmd, None, NotImplementedError) - self.assertRaises(Distro.restart_service, None, NotImplementedError) + self.assertRaises(NotImplementedError, Distro.pkg, None) + self.assertRaises(NotImplementedError, Distro.pkg_by_file, None) + self.assertRaises(NotImplementedError, Distro.restart_service_cmd, None) + self.assertRaises(NotImplementedError, Distro.restart_service, None) # Lookup methods self.assertEqual(Distro.pkg_services(Pkg), []) self.assertEqual(Distro.pkg_service_blacklist(Pkg), []) -- cgit v1.2.3 From a2e8aeb34bc615cc9c0082951721971bb141f20a Mon Sep 17 00:00:00 2001 From: Guido Günther Date: Mon, 29 Jun 2015 19:18:53 +0200 Subject: Document changes and release 0.0.10-1 --- debian/changelog | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/debian/changelog b/debian/changelog index 94fec4b..2f5407c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,14 @@ +whatmaps (0.0.10-1) unstable; urgency=medium + + * New upstream version 0.0.10: + * Add mapping for libvirt-daemon -> libvirtd. Needed for the sysv init + based systems + * Silence output if package list is empty + * Don't print overly long error message In the systemd case + * Fix assertRaises invocations. (Closes: #790372) + + -- Guido Günther Mon, 29 Jun 2015 19:18:02 +0200 + whatmaps (0.0.9-1) unstable; urgency=medium * New upstream version: -- cgit v1.2.3