Merge lp:~abentley/launchpad/no-proprietary-packagings into lp:launchpad
Status: | Merged |
---|---|
Approved by: | Aaron Bentley |
Approved revision: | no longer in the source branch. |
Merged at revision: | 16240 |
Proposed branch: | lp:~abentley/launchpad/no-proprietary-packagings |
Merge into: | lp:launchpad |
Diff against target: |
229 lines (+83/-14) 6 files modified
lib/lp/registry/browser/product.py (+9/-7) lib/lp/registry/browser/sourcepackage.py (+5/-2) lib/lp/registry/browser/tests/test_product.py (+3/-2) lib/lp/registry/browser/tests/test_sourcepackage_views.py (+62/-1) lib/lp/registry/vocabularies.py (+3/-1) lib/lp/services/webapp/vocabulary.py (+1/-1) |
To merge this branch: | bzr merge lp:~abentley/launchpad/no-proprietary-packagings |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Benji York (community) | code | Approve | |
Review via email: mp+132960@code.launchpad.net |
Commit message
No proprietary products for Upstream connections portlet.
Description of the change
= Summary =
Fix bug #1066905: OOPS on "Upstream connections" portlet with proprietary product
== Proposed fix ==
Ensure that the vocabulary lists only Public products, disable information type slection if registering a new product.
== Pre-implementation notes ==
None
== LOC Rationale ==
Part of Private Products
== Implementation details ==
Removing non-Public products from the vocabulary has two effects: it prevents the item from being listed, and it also prevents it from being accepted if submitted. (This could happen due to a race, as per test_link_
The presence of a source_package_name becomes a criterion for hiding the information_type, in addition to the feature flag.
Fixed handling of vocab_filter for SQLObjectVocabu
Fixed name of "test_owner_
== Tests ==
bin/test -t test_register_
== Demo and Q/A ==
Find a source package with no Upstream connection (or remove its connection). Register a product from the portal. You should not see the "Information Type" field.
Disconnect the product from the source package.
On the Upstream connections portal, the product should be listed as a potential connection. In another window, make the product proprietary.
Click "Link to Upstream Project". You should get "Invalid value", and the product should no longer be listed under "Upstream connections".
= 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/
This branch looks good. Considering the race condition was a good touch.