Merge ~brian-murray/ubuntu-archive-tools:no-unsub-devrelease into ubuntu-archive-tools:main

Proposed by Brian Murray
Status: Merged
Approved by: Steve Langasek
Approved revision: 6d7e67f24e8b791095331cf3f688ea4e4d8ad62c
Merged at revision: 6d7e67f24e8b791095331cf3f688ea4e4d8ad62c
Proposed branch: ~brian-murray/ubuntu-archive-tools:no-unsub-devrelease
Merge into: ubuntu-archive-tools:main
Diff against target: 33 lines (+9/-3)
1 file modified
unsubscribe-team (+9/-3)
Reviewer Review Type Date Requested Status
Steve Langasek Approve
Review via email: mp+413918@code.launchpad.net

Commit message

Don't unsubscribe from a package if it has a but with MIR in the title and the ubuntu-mir team subscribed

Description of the change

I ran unsubscribe-team foundations-bugs and it unsubscribed the foundations-bugs team from a bunch of packages which are currently undergoing MIR review. I think in this case we should trust the team to know what they want to be subscribed to and not remove the subscription.

While working on this I noticed the development release of Ubuntu is looked up but never used by anything so I just removed that.

To post a comment you must log in.
Revision history for this message
Steve Langasek (vorlon) :
review: Needs Information
Revision history for this message
Brian Murray (brian-murray) :
Revision history for this message
Steve Langasek (vorlon) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/unsubscribe-team b/unsubscribe-team
2index 172b4c4..134f585 100755
3--- a/unsubscribe-team
4+++ b/unsubscribe-team
5@@ -17,10 +17,19 @@ def unsubscribe(lp, user, ubuntu, current_packages):
6 print('Unable to find a Launchpad user named %s' % user)
7 sys.exit(1)
8
9+ mir_team = lp.people['ubuntu-mir']
10+
11 subscriptions = set([p.name for p in lpuser.getBugSubscriberPackages()])
12
13 stale_packages = subscriptions - current_packages
14 for package in stale_packages:
15+ srcpkg = ubuntu.getSourcePackage(name=package)
16+ # if the srcpkg has an open MIR bug keep the subscription
17+ mir_bug = any([task for task in
18+ srcpkg.searchTasks(bug_subscriber=mir_team)
19+ if "[MIR]" in task.title])
20+ if mir_bug:
21+ continue
22 print("Unsubscribing from %s" % package)
23 srcpkg = ubuntu.getSourcePackage(name=package)
24 srcpkg.removeBugSubscription(subscriber=lpuser)
25@@ -62,9 +71,6 @@ def main(argv):
26 continue
27 if series.active:
28 options.suites.append(series.name)
29- # find the dev series
30- if series.status in ['Active Development', 'Pre-release Freeze']:
31- options.dev_suite = series.name
32
33 current_packages = source_names(options)
34

Subscribers

People subscribed via source and target branches