From b71f803a0e60e9cefd375efaaab9e284d558bb28 Mon Sep 17 00:00:00 2001 From: Ansgar Burchardt Date: Wed, 15 Aug 2012 22:17:20 +0200 Subject: [PATCH] Also send announcements when accepting uploads from policy queues. --- dak/process_policy.py | 2 +- daklib/announce.py | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/dak/process_policy.py b/dak/process_policy.py index 30e10c4d..6dd1e36f 100755 --- a/dak/process_policy.py +++ b/dak/process_policy.py @@ -265,7 +265,7 @@ def get_processed_upload(upload): pu.changed_by = upload.changes.changedby pu.fingerprint = upload.changes.fingerprint - pu.suites = [] + pu.suites = [ upload.target_suite ] pu.from_policy_suites = [ upload.target_suite ] changes_path = os.path.join(upload.policy_queue.path, upload.changes.changesname) diff --git a/daklib/announce.py b/daklib/announce.py index 51a07d90..dec3e602 100644 --- a/daklib/announce.py +++ b/daklib/announce.py @@ -109,7 +109,7 @@ def announce_accept(upload): cnf = Config() subst = _subst_for_upload(upload) - accepted_to_real_suite = any(suite.policy_queue is None for suite in upload.suites) + accepted_to_real_suite = any(suite.policy_queue is None or suite in upload.from_policy_suites for suite in upload.suites) suite_names = [] for suite in upload.suites: @@ -127,9 +127,8 @@ def announce_accept(upload): # senf mail to announce lists and tracking server announce = set() for suite in upload.suites: - if suite.policy_queue is None: - continue - announce.update(suite.announce or []) + if suite.policy_queue is None or suite in upload.from_policy_suites: + announce.update(suite.announce or []) announce_list_address = ", ".join(announce) -- 2.39.2