Merge lp:~jcsackett/launchpad/filter-in-getRequestTargets into lp:launchpad
| Status: | Merged |
|---|---|
| Approved by: | j.c.sackett on 2012-11-21 |
| Approved revision: | no longer in the source branch. |
| Merged at revision: | 16304 |
| Proposed branch: | lp:~jcsackett/launchpad/filter-in-getRequestTargets |
| Merge into: | lp:launchpad |
| Diff against target: |
192 lines (+38/-14) 6 files modified
lib/lp/translations/browser/translationimportqueue.py (+7/-2) lib/lp/translations/doc/translationimportqueue.txt (+2/-1) lib/lp/translations/interfaces/translationimportqueue.py (+2/-1) lib/lp/translations/model/translationimportqueue.py (+8/-5) lib/lp/translations/scripts/po_import.py (+1/-1) lib/lp/translations/tests/test_translationimportqueue.py (+18/-4) |
| To merge this branch: | bzr merge lp:~jcsackett/launchpad/filter-in-getRequestTargets |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Aaron Bentley (community) | 2012-11-21 | Approve on 2012-11-21 | |
|
Review via email:
|
|||
Commit Message
Adds private product filtering to getRequestTargets in the translations import queue.
Description of the Change
Summary
=======
The import queue isn't aware of private products, because the function driving
it, get_product_
to use the privacy filter provided by ProductSet.
Preimp
======
Spoke with Rick Harding about alternatives to ILaunchBag use.
Implementation
==============
getRequestTargets is updated to take a user argument, which it passes to
get_product_
get_product_
ProductSet.
The interface is updated to include the new user argument, and supply the
REQUEST_USER as the argument for the API export.
Tests
=====
bin/test -vvct test_list_
QA
==
Ensure private products do not appear in the import queue.
LoC
===
Part of private projects.
Lint
====
Checking for conflicts and issues in changed files.
Linting changed files:
lib/lp/
lib/lp/
lib/lp/
lib/lp/

In getRequestTargets and list_product_ request_ targets, having the user default to None means that calling code can accidentally omit it. I think it should be a non-optional parameter, even though this means changing parameter order.
Other than that, this looks good to land.