Merge lp:~thumper/launchpad/recipe-inline-edit-recipe-text into lp:launchpad
Status: | Merged | ||||||||
---|---|---|---|---|---|---|---|---|---|
Approved by: | Leonard Richardson | ||||||||
Approved revision: | no longer in the source branch. | ||||||||
Merged at revision: | 12402 | ||||||||
Proposed branch: | lp:~thumper/launchpad/recipe-inline-edit-recipe-text | ||||||||
Merge into: | lp:launchpad | ||||||||
Prerequisite: | lp:~thumper/launchpad/daily-ajax | ||||||||
Diff against target: |
436 lines (+131/-56) 10 files modified
lib/canonical/launchpad/icing/style-3-0.css.in (+7/-7) lib/lp/bugs/interfaces/bugsupervisor.py (+0/-3) lib/lp/code/browser/sourcepackagerecipe.py (+7/-0) lib/lp/code/errors.py (+16/-7) lib/lp/code/interfaces/sourcepackagerecipe.py (+10/-2) lib/lp/code/model/sourcepackagerecipe.py (+13/-2) lib/lp/code/model/tests/test_sourcepackagerecipe.py (+46/-33) lib/lp/code/templates/sourcepackagerecipe-index.pt (+5/-1) lib/lp/code/windmill/tests/test_recipe_index.py (+26/-0) versions.cfg (+1/-1) |
||||||||
To merge this branch: | bzr merge lp:~thumper/launchpad/recipe-inline-edit-recipe-text | ||||||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Leonard Richardson (community) | Approve | ||
Review via email: mp+49585@code.launchpad.net |
Commit message
[r=leonardr][bug=673530,708265] Allow inline editing of the recipe text.
Description of the change
This branch adds the ability to edit the recipe text on the
main recipe page.
As part of this I've tweaked the styles so we don't get the
horrible overlap at the top of the multiline editors. I
believe this was missed during the yui 3.1 -> 3.2 transition
as the yui- prefix became yui3-.
lib/lp/
- annotated the RecipeParseError to be a 400 Bad Request error.
- also for the NoSuchBranch and PrivateBranchRecipe errors as
they can also be raised when setting recipe text
- pulled the webservice_error up to the base class instead of
having it in each of the three derived classes.
lib/lp/
- change the setRecipeText from being exported as a writable
operatioln to be a mutator for the recipe_text attribute.
I talked with Leonard about the stack of adapters here.
The operate from bottom to top.
lib/lp/
- in order to get the full error returned to the client, we
need to call the "expose" method from lazr.restful. I
chatted with Leonard about this one too as it seemed a
little strange. There was some reason at some stage, but
he couldn't recall the underlying reason at the time I
was asking. We may perhaps want to re-evaluate the need
for this method at some time.
I don't understand why you got rid of the CSS styles for edit-description and edit-commit- message. Did you already generalize those widgets, and you're just cleaning up the CSS?
Your annotations create a situation where setRecipeText is published in version 1.0 of the web service but absent in version devel, and in which you can PATCH ISourcePackageR ecipe[' recipe_ text'] in devel but not in 1.0. I'd like to see some tests of that using launchpadlib. Your windmill test only tests that you can PATCH ISourcePackageR ecipe[' recipe_ test'] in devel.
I don't think this is that big a deal, but if you care enough to distinguish between 1.0 and devel in the first place, you should test the different versions. Let me know if you need help with the tests. I'll start you out by saying that you can us launchpadlib_ for("test" , person, version="1.0") to get a launchpadlib that operates against 1.0.