Code review comment for lp:~adiroiban/launchpad/bug-497438

Revision history for this message
Adi Roiban (adiroiban) wrote :

= Bug 497438 =

While reviewing the import queue for Lucid, and as a member of rosetta-admins and ubuntu-translations-coordinators, I've noticed the following:

If I go to https://translations.edge.launchpad.net/ubuntu/lucid/+source/gfxboot-theme-ubuntu, I can see the list of templates for that package in my preferred languages.

However, when I try to access the template page at https://translations.edge.launchpad.net/ubuntu/lucid/+source/gfxboot-theme-ubuntu/+pots/bootloader, I get a "Translation page is not available. Translations for this release series are not available yet." error message and cannot access the page. The same happens when I try to access the +admin page.

== Implementation details ==
Since we are migrating translations permission from launchpad.Admin to launchpad.TranslationsAdmin, just replace launchpad.Admin with launchpad.TranslationsAdmin in the appropriate places.

The tests from distroseries-translations were switched from admin_browser to utc_browser, a browser configured for launchpad.TranslationsAdmin

Also there were some productseries tests and they were moved. Same for language specific tests.

After talking with Danilo, we agreed of having an utility (helper) function for setting up a browser configured for launchpad.TranslationsAdmin

== Tests ==

bin/test -vvct distroseries-translations

== Demo and Q/A ==
Login in Launchpad as RosettaExpert (carlos) or a member of distribution translation group.

Go to distroseries translation setting page and hide the translations
https://translations.launchpad.dev/ubuntu/hoary/+admin

You should still be able to browse distroseries translations:
https://translations.launchpad.dev/ubuntu/hoary
https://translations.launchpad.dev/ubuntu/hoary/+lang/es

Login as a normal user or anonymous. Visit those pages again.
You should see a message telling you the translations are not available yet.

= Launchpad lint =

Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.

Linting changed files:
  lib/canonical/launchpad/testing/pages.py
  lib/lp/registry/browser/distroseries.py
  lib/lp/registry/browser/sourcepackage.py
  lib/lp/translations/stories/distroseries/xx-distroseries-translations.txt

== Pylint notices ==

lib/canonical/launchpad/testing/pages.py
    39: [F0401] Unable to import 'lazr.restful.testing.webservice' (No module named restful)

lib/lp/registry/browser/sourcepackage.py
    23: [F0401] Unable to import 'lazr.restful.interface' (No module named restful)

I have not touched the lazr.restful part. Those lint warning were already there.

« Back to merge proposal