upgradecheck upgradecheck.py,1.8,1.9
Ville Skytta (scop)
fedora-extras-commits at redhat.com
Sun Jun 18 10:15:31 UTC 2006
Author: scop
Update of /cvs/fedora/upgradecheck
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv21623
Modified Files:
upgradecheck.py
Log Message:
Q'n'd workaround for false positives (eg. #195815), perhaps to be fixed for real some day.
Index: upgradecheck.py
===================================================================
RCS file: /cvs/fedora/upgradecheck/upgradecheck.py,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- upgradecheck.py 18 Jun 2006 10:05:06 -0000 1.8
+++ upgradecheck.py 18 Jun 2006 10:15:29 -0000 1.9
@@ -37,10 +37,16 @@
# and all repos containing that number in their id's will be associated with
# the corresponding distro version. For example, repo id "foo9bar" will be
# associated with distro "9".
-
dists = ('3', '4', '5', '6')
+
+# Architectures to operate on.
archs = rpmUtils.arch.getArchList('src')
+# False positive workaround: per-dist lists of package names that produce
+# false positives. Include only the exact problem spots here.
+known_good = {'4': ['koffice']}
+
+
def parseArgs():
usage = "usage: %s [-n] [-c <config file>] [-a <arch>] [-r <repoid>] [-r <repoid2>]" % sys.argv[0]
parser = OptionParser(usage=usage)
@@ -139,24 +145,32 @@
report = []
+ for dist in enabled_dists:
+ if not known_good.get(dist):
+ known_good[dist] = []
+
for name in allnames:
pkgdata = map(lambda x: pkgdict[x].get(name), enabled_dists)
- last = None # last seen EVR
- bork = None # index of first repo w/ problem
+ last = None # last seen EVR
+ bork = None # index of first repo w/ problem
ix = 0
for curr in pkgdata:
- if not curr: # missing
- pass # TODO: detect holes in continuum
- elif last is None: # first one seen
+ if not curr:
+ # package missing from this repo
+ # TODO: detect holes in continuum
+ pass
+ elif last is None or name in known_good[enabled_dists[ix]]:
+ # first one seen or "known good" workaround
last = curr["evr"]
- elif compareEVR(last, curr["evr"]) > 0: # versioning problem
+ elif compareEVR(last, curr["evr"]) > 0:
+ # versioning problem
bork = ix - 1
break
ix = ix + 1
if bork is not None:
ix = bork
report.append(name + ":")
- for curr in pkgdata[ix:]: # onwards from the problem spot
+ for curr in pkgdata[ix:]: # onwards from the problem spot
report.append(" %s: %s (%s)" % (enabled_dists[ix], evrstr(curr["evr"]), curr["repo"]))
ix = ix + 1
report.append("")
More information about the fedora-extras-commits
mailing list