Merge lp:~bryce/launchpad/lp-31745-237126-617102 into lp:launchpad

Proposed by Bryce Harrington
Status: Merged
Approved by: Bryce Harrington
Approved revision: no longer in the source branch.
Merged at revision: 11434
Proposed branch: lp:~bryce/launchpad/lp-31745-237126-617102
Merge into: lp:launchpad
Diff against target: 56 lines (+16/-5)
2 files modified
lib/lp/bugs/doc/externalbugtracker-bugzilla.txt (+3/-1)
lib/lp/bugs/externalbugtracker/bugzilla.py (+13/-4)
To merge this branch: bzr merge lp:~bryce/launchpad/lp-31745-237126-617102
Reviewer Review Type Date Requested Status
Deryck Hodge (community) code Approve
Launchpad code reviewers Pending
Review via email: mp+33182@code.launchpad.net

Commit message

[bug=31745][bug=237126][bug=617102][ui=none][r=] Improve mapping of unusual Bugzilla statuses and resolutions to more appropriate Launchpad status values.

Description of the change

This fixes three bugs relating to the mapping of bugzilla statuses to Launchpad statuses.
(LP: #31745, #237126, #617102).

Different bugzilla instances sometimes add custom statuses and resolutions beyond the defaults; we have tracked some of these, this branch adds several more.

We also recently added an Expired status to Launchpad. This branch takes advantage of this by mapping a few relevant Bugzilla resolutions to it.

For situations where the bug was closed with an unrecognized resolution, we had been mapping those unknown resolutions to be status 'Invalid'. Instead, this branch explicitly maps resolutions that *should* be invalid to Invalid, and any other unknown resolutions map to status 'Unknown'.

I've tested this using 'test -t bugzilla' and run it successfully through ec2 test.
I've done a lint check and verified this branch adds no new lint errors.

To post a comment you must log in.
Revision history for this message
Deryck Hodge (deryck) :
review: Approve (code)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lib/lp/bugs/doc/externalbugtracker-bugzilla.txt'
2--- lib/lp/bugs/doc/externalbugtracker-bugzilla.txt 2010-08-13 20:33:45 +0000
3+++ lib/lp/bugs/doc/externalbugtracker-bugzilla.txt 2010-08-24 16:34:41 +0000
4@@ -290,6 +290,8 @@
5 'Fix Committed'
6 >>> external_bugzilla.convertRemoteStatus('RESOLVED FIXED').title
7 'Fix Released'
8+ >>> external_bugzilla.convertRemoteStatus('RESOLVED UPSTREAM').title
9+ "Won't Fix"
10 >>> external_bugzilla.convertRemoteStatus(
11 ... 'CLOSED PATCH_ALREADY_AVAILABLE').title
12 'Fix Released'
13@@ -300,7 +302,7 @@
14 >>> external_bugzilla.convertRemoteStatus('CLOSED INVALID').title
15 'Invalid'
16 >>> external_bugzilla.convertRemoteStatus('CLOSED UPSTREAM').title
17- 'Fix Released'
18+ "Won't Fix"
19
20 If the status can't be converted an UnknownRemoteStatusError will be
21 returned.
22
23=== modified file 'lib/lp/bugs/externalbugtracker/bugzilla.py'
24--- lib/lp/bugs/externalbugtracker/bugzilla.py 2010-08-21 07:31:45 +0000
25+++ lib/lp/bugs/externalbugtracker/bugzilla.py 2010-08-24 16:34:41 +0000
26@@ -254,6 +254,7 @@
27 ('ASSIGNED', 'ON_DEV', 'FAILS_QA', 'STARTED',
28 BugTaskStatus.INPROGRESS),
29 ('NEEDINFO', 'NEEDINFO_REPORTER', 'WAITING', 'SUSPENDED',
30+ 'PLEASETEST',
31 BugTaskStatus.INCOMPLETE),
32 ('PENDINGUPLOAD', 'MODIFIED', 'RELEASE_PENDING', 'ON_QA',
33 BugTaskStatus.FIXCOMMITTED),
34@@ -261,11 +262,19 @@
35 ('RESOLVED', 'VERIFIED', 'CLOSED',
36 LookupTree(
37 ('CODE_FIX', 'CURRENTRELEASE', 'ERRATA', 'NEXTRELEASE',
38- 'PATCH_ALREADY_AVAILABLE', 'FIXED', 'RAWHIDE', 'UPSTREAM',
39+ 'PATCH_ALREADY_AVAILABLE', 'FIXED', 'RAWHIDE',
40+ 'DOCUMENTED',
41 BugTaskStatus.FIXRELEASED),
42- ('WONTFIX', BugTaskStatus.WONTFIX),
43- (BugTaskStatus.INVALID, ))),
44- ('REOPENED', 'NEW', 'UPSTREAM', 'DEFERRED', BugTaskStatus.CONFIRMED),
45+ ('WONTFIX', 'WILL_NOT_FIX', 'NOTOURBUG', 'UPSTREAM',
46+ BugTaskStatus.WONTFIX),
47+ ('OBSOLETE', 'INSUFFICIENT_DATA', 'INCOMPLETE', 'EXPIRED',
48+ BugTaskStatus.EXPIRED),
49+ ('INVALID', 'WORKSFORME', 'NOTABUG', 'CANTFIX',
50+ 'UNREPRODUCIBLE',
51+ BugTaskStatus.INVALID),
52+ (BugTaskStatus.UNKNOWN,))),
53+ ('REOPENED', 'NEW', 'UPSTREAM', 'DEFERRED',
54+ BugTaskStatus.CONFIRMED),
55 ('UNCONFIRMED', BugTaskStatus.NEW),
56 )
57