Merge lp:~jpds/arsenal/css-subscribed into lp:arsenal/trunk

Proposed by Jonathan Davies
Status: Needs review
Proposed branch: lp:~jpds/arsenal/css-subscribed
Merge into: lp:arsenal/trunk
Diff against target: 159 lines (+92/-5)
3 files modified
reports/cbd (+25/-5)
reports/css/rls-mgr-p-css-tracking.json (+35/-0)
reports/css/rls-p-css-tracking.json (+32/-0)
To merge this branch: bzr merge lp:~jpds/arsenal/css-subscribed
Reviewer Review Type Date Requested Status
Brad Figg code Pending
Review via email: mp+98529@code.launchpad.net

Description of the change

This branch allows one to specify a subscriber field to JSON files. Only bugs with that subscriber will be thus listed.

To post a comment you must log in.
Revision history for this message
Brad Figg (brad-figg) wrote :

On 03/20/2012 03:15 PM, Jonathan Davies wrote:
> Jonathan Davies has proposed merging lp:~jpds/arsenal/css-subscribed into lp:arsenal.
>
> Requested reviews:
> Brad Figg (brad-figg): code
>
> For more details, see:
> https://code.launchpad.net/~jpds/arsenal/css-subscribed/+merge/98529
>
> This branch allows one to specify a subscriber field to JSON files. Only bugs with that subscriber will be thus listed.

This fails for .json files that do not have a "subscriber" entry
in them. That will need to be fixed.

Brad
--
Brad Figg <email address hidden> http://www.canonical.com

lp:~jpds/arsenal/css-subscribed updated
963. By Jonathan Davies

Make reports/cbd set search_subscriber to None instead of an empty string.

Revision history for this message
Jonathan Davies (jpds) wrote :

> This fails for .json files that do not have a "subscriber" entry
> in them. That will need to be fixed.

Fixed in r963.

lp:~jpds/arsenal/css-subscribed updated
964. By Jonathan Davies

Finalize CSS bug reports.

Unmerged revisions

964. By Jonathan Davies

Finalize CSS bug reports.

963. By Jonathan Davies

Make reports/cbd set search_subscriber to None instead of an empty string.

962. By Jonathan Davies

Fixed Dbg output for subscriber.

961. By Jonathan Davies

Improved search_subscriber code.

960. By Jonathan Davies

Corrected subscribers → subscriber typo change.

959. By Jonathan Davies

Added reports/rls-mgr/rls-mgr-p-css-tracking.json.

958. By Jonathan Davies

Adapted cbd to take a subscriber option.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'reports/cbd'
2--- reports/cbd 2012-03-13 20:58:18 +0000
3+++ reports/cbd 2012-03-21 14:43:19 +0000
4@@ -309,6 +309,12 @@
5 Dbg.verbose('search: reporters: \'%s\'\n' % ','.join(reporters))
6
7 try:
8+ subscriber = search_criteria['subscriber']
9+ except KeyError:
10+ subscriber = ''
11+ Dbg.verbose('search: subscriber: \'%s\'\n' % subscriber)
12+
13+ try:
14 assignees = search_criteria['assignees']
15 except KeyError:
16 assignees = ''
17@@ -318,13 +324,19 @@
18 print('You must choose either assignees or reporters not both!')
19 exit(1)
20
21+ if subscriber:
22+ search_subscriber = self.lp.launchpad.people[subscriber]
23+ else:
24+ search_subscriber = None
25+
26 Dbg.leave("CollectBugData.distro_tasks_search")
27 if reporters != '':
28 tasks = []
29 for reporter in reporters:
30 search_reporter = self.lp.launchpad.people[reporter]
31 if search_reporter.is_team is False:
32- for task in distro.search_tasks(tags=search_tags,
33+ for task in distro.search_tasks(bug_subscriber=search_subscriber,
34+ tags=search_tags,
35 tags_combinator=search_tags_combinator,
36 status=search_status, bug_reporter=search_reporter,
37 modified_since=last_run_time):
38@@ -333,7 +345,9 @@
39 for participant in search_reporter.participants:
40 if participant.is_team:
41 continue
42- for task in distro.search_tasks(tags=search_tags,
43+ for task in distro.search_tasks(
44+ bug_subscriber=search_subscriber,
45+ tags=search_tags,
46 tags_combinator=search_tags_combinator,
47 status=search_status, bug_reporter=participant,
48 modified_since=last_run_time):
49@@ -344,7 +358,9 @@
50 for assignee in assignees:
51 search_assignee = self.lp.launchpad.people[assignee]
52 if search_assignee.is_team is False:
53- for task in distro.search_tasks(tags=search_tags,
54+ for task in distro.search_tasks(
55+ bug_subscriber=search_subscriber,
56+ tags=search_tags,
57 tags_combinator=search_tags_combinator,
58 status=search_status, assignee=search_assignee,
59 modified_since=last_run_time):
60@@ -353,14 +369,18 @@
61 for participant in search_assignee.participants:
62 if participant.is_team:
63 continue
64- for task in distro.search_tasks(tags=search_tags,
65+ for task in distro.search_tasks(
66+ bug_subscriber=search_subscriber,
67+ tags=search_tags,
68 tags_combinator=search_tags_combinator,
69 status=search_status, assignee=participant,
70 modified_since=last_run_time):
71 tasks.append(task)
72 return tasks
73 else:
74- return distro.search_tasks(tags=search_tags,
75+ return distro.search_tasks(
76+ bug_subscriber=search_subscriber,
77+ tags=search_tags,
78 tags_combinator=search_tags_combinator, status=search_status,
79 modified_since=last_run_time)
80
81
82=== added directory 'reports/css'
83=== added file 'reports/css/rls-mgr-p-css-tracking.json'
84--- reports/css/rls-mgr-p-css-tracking.json 1970-01-01 00:00:00 +0000
85+++ reports/css/rls-mgr-p-css-tracking.json 2012-03-21 14:43:19 +0000
86@@ -0,0 +1,35 @@
87+{
88+ "launchpad_config": {
89+ "launchpad_client_name": "rls-mgr-reports",
90+ "read_only": false
91+ },
92+ "search_criteria": [
93+ {
94+ "distribution": "ubuntu",
95+ "series": [
96+ "precise",
97+ "NONE"
98+ ],
99+ "status": [
100+ "New",
101+ "Confirmed",
102+ "Triaged",
103+ "Incomplete",
104+ "Incomplete (with response)",
105+ "Incomplete (without response)",
106+ "In Progress",
107+ "Fix Committed"
108+ ],
109+ "subscriber": "canonical-support",
110+ "tags": [
111+ "rls-mgr-p-tracking"
112+ ]
113+ }
114+ ],
115+ "tasks": {
116+ "865672": [],
117+ "926263": [],
118+ "949782": []
119+ },
120+ "update_timestamp": "Tuesday, 20. March 2012 21:49 UTC"
121+}
122\ No newline at end of file
123
124=== added file 'reports/css/rls-p-css-tracking.json'
125--- reports/css/rls-p-css-tracking.json 1970-01-01 00:00:00 +0000
126+++ reports/css/rls-p-css-tracking.json 2012-03-21 14:43:19 +0000
127@@ -0,0 +1,32 @@
128+{
129+ "launchpad_config": {
130+ "launchpad_client_name": "rls-mgr-reports",
131+ "read_only": false
132+ },
133+ "search_criteria": [
134+ {
135+ "distribution": "ubuntu",
136+ "series": [
137+ "precise",
138+ "NONE"
139+ ],
140+ "status": [
141+ "New",
142+ "Confirmed",
143+ "Triaged",
144+ "Incomplete",
145+ "Incomplete (with response)",
146+ "Incomplete (without response)",
147+ "In Progress",
148+ "Fix Committed"
149+ ],
150+ "subscriber": "canonical-support",
151+ "tags": [
152+ "rls-p-tracking"
153+ ]
154+ }
155+ ],
156+ "tasks": {
157+ },
158+ "update_timestamp": "Tuesday, 20. March 2012 21:49 UTC"
159+}

Subscribers

People subscribed via source and target branches

to status/vote changes: