X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=dak%2Fauto_decruft.py;h=66479a47fd863f155257a37c9d3bfdf61c9d7bdd;hb=98d086ddda3772fb58c1bfa97478e8044596b569;hp=1586fe10fb0365e81243c971d93d138055239c0f;hpb=3ce70f930d27b0769737b841c598d192b595180c;p=dak.git diff --git a/dak/auto_decruft.py b/dak/auto_decruft.py index 1586fe10..66479a47 100644 --- a/dak/auto_decruft.py +++ b/dak/auto_decruft.py @@ -219,15 +219,15 @@ def auto_decruft_suite(suite_name, suite_id, session, dryrun, debug): ) for group in group_generator: group_name = group["name"] + pkgs = group["packages"] + affected_archs = group["architectures"] + # If we remove an arch:all package, then the breakage can occur on any + # of the architectures. + if "all" in affected_archs: + affected_archs = all_architectures + for pkg_arch in product(pkgs, affected_archs): + pkg_arch2groups[pkg_arch].add(group_name) if group_name not in groups: - pkgs = group["packages"] - affected_archs = group["architectures"] - # If we remove an arch:all package, then the breakage can occur on any - # of the architectures. - if "all" in affected_archs: - affected_archs = all_architectures - for pkg_arch in product(pkgs, affected_archs): - pkg_arch2groups[pkg_arch].add(group_name) groups[group_name] = group group_order.append(group_name) else: @@ -454,6 +454,9 @@ def main (): osuite = get_suite(Options["OtherSuite"].lower(), session).suite_name decruft_newer_version_in(osuite, suite_name, suite_id, Options["OtherSuiteRMMsg"], session, dryrun) + if not dryrun: + session.commit() + ################################################################################ if __name__ == '__main__':