Control: tags -1 + patch Hello Don & the team,
time flies, already 7 years since I filed that bug :) As we were trying to get rid of packages.qa.debian.org with Philip Kern, I rediscovered that the BTS still sends mails to packages.qa.debian.org instead of tracker.debian.org. So I had a quick look at the code and tried to produce a patch. Please find it attached. It looks like we have two different ways to figuring out the recipients, and one might not yet be in active use... not exactly sure. In any case, I updated both places. It would be really nice if you could review and fix/merge as appropriate, and deploy it so that we can rid of packages.qa.debian.org for good. Thank you in advance. -- ⢀⣴⠾⠻⢶⣦⠀ Raphaël Hertzog <[email protected]> ⣾⠁⢠⠒⠀⣿⡁ ⢿⡄⠘⠷⠚⠋ The Debian Handbook: https://debian-handbook.info/get/ ⠈⠳⣄⠀⠀⠀⠀ Debian Long Term Support: https://deb.li/LTS
>From eb618527051a88236c04fa135bfdb25e24acb545 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Hertzog?= <[email protected]> Date: Sat, 16 Aug 2025 19:26:05 +0200 Subject: [PATCH] Simplify logic to forward mails to tracker.debian.org I'm not sure in what context Debbugs::Recipients is used but there it now relies on the config parameter 'cc_all_mails_to_addr' and I put it as an example in examples/config.debian. scripts/process seems to be not relying on Debbugs::Recipients so I simply changed the logic to add a copy to dispatch@$config{subscription_domain} and I dropped the logic to add one recipient per source package. From what I can see, in the end Debbugs sends a single email to many recipients, so tracker.debian.org doesn't need multiple copies. It knows how to reconstitute the list of affected source packages. --- examples/config.debian | 5 ++++- lib/Debbugs/Recipients.pm | 23 +---------------------- scripts/process | 15 +-------------- 3 files changed, 6 insertions(+), 37 deletions(-) diff --git a/examples/config.debian b/examples/config.debian index 193e7b5..5f51787 100644 --- a/examples/config.debian +++ b/examples/config.debian @@ -10,7 +10,10 @@ $gHTMLSuffix = ""; $gPackagePages = "packages.debian.org"; $gCGIDomain = "bugs.debian.org/cgi-bin"; $gMirrors = ""; # comma separated list -$gSubscriptionDomain = "packages.qa.debian.org"; + +# Tracker integration +$gSubscriptionDomain = "tracker.debian.org"; +$gCcAllMailsToAddr = "[email protected]"; # Project identification $gProject = "Debian"; diff --git a/lib/Debbugs/Recipients.pm b/lib/Debbugs/Recipients.pm index 29b92f7..196654f 100644 --- a/lib/Debbugs/Recipients.pm +++ b/lib/Debbugs/Recipients.pm @@ -115,27 +115,6 @@ sub add_recipients { my $ref = $param{data}{bug_num}; for my $p (splitpackages($param{data}{package})) { $p = lc($p); - if (defined $config{subscription_domain}) { - my @source_packages = binary_to_source(binary => $p, - source_only => 1, - ); - if (@source_packages) { - for my $source (@source_packages) { - _add_address(recipients => $param{recipients}, - address => "$source\@".$config{subscription_domain}, - reason => $source, - type => 'bcc', - ); - } - } - else { - _add_address(recipients => $param{recipients}, - address => "$p\@".$config{subscription_domain}, - reason => $p, - type => 'bcc', - ); - } - } if (defined $param{data}{severity} and defined $config{strong_list} and isstrongseverity($param{data}{severity})) { _add_address(recipients => $param{recipients}, @@ -186,7 +165,7 @@ sub add_recipients { length $config{cc_all_mails_to_addr} ) { _add_address(recipients => $param{recipients}, - address => $config{cc_all_mails_to}, + address => $config{cc_all_mails_to_addr}, reason => "cc_all_mails_to", bug_num => $param{data}{bug_num}, type => 'bcc', diff --git a/scripts/process b/scripts/process index 8310998..4de6ffa 100755 --- a/scripts/process +++ b/scripts/process @@ -155,7 +155,6 @@ our $maintainerschecked = 0; #maintainer address for this message our @maintaddrs; # other src addresses -our @addsrcaddrs; our @resentccs; our @bccs; @@ -483,7 +482,7 @@ if ($codeletter eq 'D' || $codeletter eq 'F') # This array is used to specify bcc in the cases where we're using create_mime_message. my @generalbcc = @generalcc; if (defined $config{subscription_domain} and length $config{subscription_domain}) { - @generalbcc = (@generalbcc, @addsrcaddrs); + @generalbcc = (@generalbcc, 'dispatch@'.$config{subscription_domain}); } if (defined $config{bug_subscription_domain} and length $config{bug_subscription_domain}) { @generalbcc = (@generalbcc, "bugs=$ref\@$config{bug_subscription_domain}"); @@ -766,7 +765,6 @@ if (@maintaddrs && ($codeletter eq 'B' || $codeletter eq 'M')) { ); } -@bccs = @addsrcaddrs; if (defined $gStrongList and isstrongseverity($data->{severity})) { push @bccs, "$gStrongList\@$gListDomain"; } @@ -1315,17 +1313,6 @@ sub checkmaintainers { $p =~ /((?:src:)?[a-z0-9.+-]+)/; $p = $1; next unless defined $p; - if (defined $config{subscription_domain} and length $config{subscription_domain}) { - my @source = binary_to_source(binary => $p, - source_only => 1, - ); - if (@source) { - push @addsrcaddrs, - map {"$_\@$config{subscription_domain}"} @source; - } else { - push @addsrcaddrs, "$p\@$config{subscription_domain}"; - } - } # this is utter hackery until we switch to Debbugs::Recipients my @maints = package_maintainer(binary => $p); if (@maints) { -- 2.50.1

