Merge lp:~abentley/launchpad/resubmit-change-branch into lp:launchpad
| Status: | Merged | ||||
|---|---|---|---|---|---|
| Approved by: | Aaron Bentley on 2010-11-05 | ||||
| Approved revision: | no longer in the source branch. | ||||
| Merged at revision: | 11904 | ||||
| Proposed branch: | lp:~abentley/launchpad/resubmit-change-branch | ||||
| Merge into: | lp:launchpad | ||||
| Diff against target: |
407 lines (+218/-31) 6 files modified
lib/lp/code/browser/branchmergeproposal.py (+37/-5) lib/lp/code/browser/tests/test_branchmergeproposal.py (+94/-1) lib/lp/code/interfaces/branchmergeproposal.py (+25/-11) lib/lp/code/model/branchmergeproposal.py (+20/-8) lib/lp/code/model/tests/test_branchmergeproposal.py (+38/-0) lib/lp/code/templates/branchmergeproposal-resubmit.pt (+4/-6) |
||||
| To merge this branch: | bzr merge lp:~abentley/launchpad/resubmit-change-branch | ||||
| Related bugs: |
|
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Paul Hummer (community) | ui | 2010-11-04 | Approve on 2010-11-05 |
| Brad Crittenden (community) | code | 2010-11-04 | Approve on 2010-11-05 |
|
Review via email:
|
|||
Commit Message
Allow changing branches, description when resubmitting merge proposal.
Description of the Change
= Summary =
Fix bug #504369: Resubmit should allow changing the branches
Screenshot: http://
== Proposed fix ==
Add fields for the branches to the resubmit page. Also allow changing the
description. Also allow the user to break the link between the old and new
proposals.
== Pre-implementation notes ==
None
== Implementation details ==
Changed the schema to ResubmitSchema to add the break_link boolean.
Changed from MergeProposalEd
adapt BranchMergeProposal to ResubmitSchema.
Changed the text to reflect the fact that users now control the branches.
Changed the text to refer to the current merge proposal as "this proposal",
since the new one doesn't exist yet.
== Tests ==
bin/test -vt proposal code
== Demo and Q/A ==
Create a merge proposal. Resubmit it, changing all branches, description, and
selecting "break link". A new proposal should be created with the specified
branches and description, and with no link to the previous one. The previous
one should be marked "superseded".
= Launchpad lint =
Checking for conflicts and issues in changed files.
Linting changed files:
lib/lp/
lib/lp/
lib/lp/
lib/lp/
lib/lp/
lib/lp/
./lib/lp/
986: E202 whitespace before ']'
988: E301 expected 1 blank line, found 0
| Aaron Bentley (abentley) wrote : | # |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 11/05/2010 01:42 AM, Brad Crittenden wrote:
> Finally, it is clear you thought it out since you test for it explicitly, but I question the need to create a new merge proposal when nothing has changed. Do you have a good use case for that?
Actually, that was the existing functionality. It is for cases where
the proposal is marked "resubmit", many changes are made, and finally
the proposal is resubmitted.
Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://
iEYEARECAAYFAkz
wUUAnjmKdw60t5e
=houq
-----END PGP SIGNATURE-----
| Paul Hummer (rockstar) wrote : | # |
As discussed on the phone, I'm of the opinion that we should ensure that both the source and the target aren't changed. In cases like that, I think that we should encouraging people to create a whole new merge proposal. I've been outvoted in this case, but I thought I'd mention it in the MP just for history's sake.

Thanks for the very nice cover letter Aaron.
The lint issues both look real and need to be fixed. The list for field_names should be multi-line with one entry per line ending with a trailing comma.
In 'initial_values' the list 'values' is really key, value pairs so calling it 'items' would make more sense.
In 'test_resubmit_ text' your use of string concatenation the call to 'assertTextMatc hes...' is hard to read. Using a variable like
expected = '...'
would be more readable.
s/If this is the same as the target branch/
If this branch is the same as the target branch
Please provide a 'cancel_url' so that you get a cancel link.
Finally, it is clear you thought it out since you test for it explicitly, but I question the need to create a new merge proposal when nothing has changed. Do you have a good use case for that?
This new functionality is a vast improvement. Thanks for recognizing the need and providing the solution.