From 4b7422886722e9d6cf3ebe9060d307c966559ccf Mon Sep 17 00:00:00 2001 From: Iain Lane Date: Tue, 7 Jul 2020 16:58:09 +0100 Subject: [PATCH] britney: Allow breaking of packages on one arch when removing cruft If all smooth updating/cruft is on a BREAK_ARCH then this can legitimately happen. --- britney.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/britney.py b/britney.py index 25e7bba..977087a 100755 --- a/britney.py +++ b/britney.py @@ -1010,7 +1010,7 @@ class Britney(object): return (nuninst_last_accepted, maybe_rescheduled_packages) - def do_all(self, hinttype=None, init=None, actions=None): + def do_all(self, hinttype=None, init=None, actions=None, break_ok=False): """Testing update runner This method tries to update testing checking the uninstallability @@ -1118,7 +1118,7 @@ class Britney(object): better = True else: break_arches = set(self.options.break_arches) - if all(x.architecture in break_arches for x in selected): + if all(x.architecture in break_arches for x in selected) and not break_ok: # If we only migrated items from break-arches, then we # do not allow any regressions on these architectures. # This usually only happens with hints @@ -1292,7 +1292,7 @@ class Britney(object): if removals: output_logger.info("Removing packages left in the target suite (e.g. smooth updates or cruft)") log_and_format_old_libraries(self.output_logger, removals) - self.do_all(actions=removals) + self.do_all(actions=removals, break_ok=True) removals = old_libraries(self._migration_item_factory, self.suite_info, self.options.outofsync_arches) output_logger.info("List of old libraries in the target suite (%d):", len(removals))