Merge lp:~benji/launchpad/bug-903532 into lp:launchpad
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Benji York | ||||
Approved revision: | no longer in the source branch. | ||||
Merged at revision: | 14639 | ||||
Proposed branch: | lp:~benji/launchpad/bug-903532 | ||||
Merge into: | lp:launchpad | ||||
Diff against target: |
161 lines (+117/-1) 3 files modified
database/schema/security.cfg (+1/-0) lib/lp/translations/model/pofilestatsjob.py (+18/-0) lib/lp/translations/tests/test_pofilestatsjob.py (+98/-1) |
||||
To merge this branch: | bzr merge lp:~benji/launchpad/bug-903532 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Benji York (community) | Approve | ||
Review via email: mp+86820@code.launchpad.net |
Commit message
[r=benji] make POFile statistics update jobs also update the stats for related POFiles
Description of the change
Bug 903532 is about a task that was thought to have been done, but half
still needed to be done. This branch does the other half.
The root issue is that when updating the statistics for a POFile, any
POFiles that share translations with the original POFile need to be
updated as well.
The new code (in pofilestatsjob.py) simply loops over all the POFiles
that share translations with the POFile associated with the job and, if
the languages match, updates their statistics as well.
The tests can be run with this command:
bin/test -c -m lp.translations
QA:
1) Note the statistics for the translations listed in bug 904012 (a
related bug)
2) Make a suggestion for one of those translations
3) Get webops to run cronscripts/
4) Check to see if both the statistics for the translation you changed
were updated as well as the statistics for the shared translation
Lint: the "make lint" report is clean.
This MP is for a bug-fix version of the branch that failed QA. The fix
wasn't involved (see discussion on [1]_ for full details) so I'm just
self-reviewing the changes.
.. [1] https:/ /code.launchpad .net/~benji/ launchpad/ bug-903532/ +merge/ 86426