britney.py: Skip lundo maintenance in non-hint recurse runs

There are no uses of "lundo" left for a non-hint recurse run (i.e.
the "main run"), so there is no point in building it.

The "lundo"-list is still used in the recurse run of a "hint"-hint.

Signed-off-by: Niels Thykier <niels@thykier.net>
debian
Niels Thykier 11 years ago
parent 04afa83ad8
commit 822d847c11

@ -1915,7 +1915,7 @@ class Britney(object):
return (adds, rms, set(smoothbins.itervalues())) return (adds, rms, set(smoothbins.itervalues()))
def doop_source(self, item, hint_undo=[], removals=frozenset()): def doop_source(self, item, hint_undo=None, removals=frozenset()):
"""Apply a change to the testing distribution as requested by `pkg` """Apply a change to the testing distribution as requested by `pkg`
An optional list of undo actions related to packages processed earlier An optional list of undo actions related to packages processed earlier
@ -2048,7 +2048,7 @@ class Britney(object):
affected.update(get_reverse_tree(j, parch)) affected.update(get_reverse_tree(j, parch))
old_version = old_pkg_data[VERSION] old_version = old_pkg_data[VERSION]
inst_tester.remove_testing_binary(binary, old_version, parch) inst_tester.remove_testing_binary(binary, old_version, parch)
else: elif hint_undo:
# the binary isn't in testing, but it may have been at # the binary isn't in testing, but it may have been at
# the start of the current hint and have been removed # the start of the current hint and have been removed
# by an earlier migration. if that's the case then we # by an earlier migration. if that's the case then we
@ -2205,9 +2205,6 @@ class Britney(object):
dependencies = self.dependencies dependencies = self.dependencies
check_packages = partial(self._check_packages, binaries) check_packages = partial(self._check_packages, binaries)
if lundo is None:
lundo = []
self.output_write("recur: [%s] %s %d/%d\n" % ("", ",".join(x.uvname for x in selected), len(packages), len(extra))) self.output_write("recur: [%s] %s %d/%d\n" % ("", ",".join(x.uvname for x in selected), len(packages), len(extra)))
# loop on the packages (or better, actions) # loop on the packages (or better, actions)
@ -2261,7 +2258,8 @@ class Britney(object):
# check if the action improved the uninstallability counters # check if the action improved the uninstallability counters
if better: if better:
lundo.append((undo, item)) if lundo is not None:
lundo.append((undo, item))
selected.append(item) selected.append(item)
packages.extend(extra) packages.extend(extra)
extra = [] extra = []

Loading…
Cancel
Save