[Piuparts-commits] [SCM] piuparts git repository branch, develop, updated. 0.51-38-g36d46ff
Andreas Beckmann
anbe at debian.org
Thu May 23 09:03:40 UTC 2013
The following commit has been merged in the develop branch:
commit 36d46ff0cba0aeaa62302bcd316f4d83a06cbafa
Author: Andreas Beckmann <anbe at debian.org>
Date: Thu May 23 10:39:00 2013 +0200
p-s: skip upgrade tests involving downgrades
Report these tests as untestable.
Downgrades 'happen' e.g. in stable2bpo2testing if the version in backports
is (temporarily) newer than testing.
Signed-off-by: Andreas Beckmann <anbe at debian.org>
diff --git a/debian/changelog b/debian/changelog
index bc67ce2..7258dbe 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -9,6 +9,7 @@ piuparts (0.52) UNRELEASED; urgency=low
* piupartslib/packagesdb.py:
* piuparts-master-backend.py:
* piuparts-slave.py:
+ - Report upgrade tests involving downgrades as untestable.
* piuparts-analyze.py:
- Consider archived bugs, too. (Closes: #669966)
* piuparts-report.py:
diff --git a/piuparts-slave.py b/piuparts-slave.py
index c5c7f00..6c8897e 100644
--- a/piuparts-slave.py
+++ b/piuparts-slave.py
@@ -35,11 +35,14 @@ import subprocess
import fcntl
import random
import ConfigParser
+import apt_pkg
import piupartslib.conf
import piupartslib.packagesdb
from piupartslib.conf import MissingSection
+apt_pkg.init_system()
+
CONFIG_FILE = "/etc/piuparts/piuparts.conf"
DISTRO_CONFIG_FILE = "/etc/piuparts/distros.conf"
@@ -683,6 +686,16 @@ class Section:
if pname in packages_files[distro]:
packages_files[distro][pname].dump(output)
output.write("\n")
+
+ if ret == 0:
+ prev = "~"
+ for distro in distros:
+ if pname in packages_files[distro]:
+ v = packages_files[distro][pname]["Version"]
+ if not apt_pkg.version_compare(prev, v) <= 0:
+ output.write("Upgrade to %s requires downgrade: %s > %s\n" % (distro, prev, v))
+ ret = -10006
+ prev = v
else:
ret = -10010
if ret != 0:
--
piuparts git repository
More information about the Piuparts-commits
mailing list