Merge lp:~adiroiban/launchpad/bug-561355 into lp:launchpad
Status: | Merged |
---|---|
Approved by: | Aaron Bentley |
Approved revision: | no longer in the source branch. |
Merged at revision: | not available |
Proposed branch: | lp:~adiroiban/launchpad/bug-561355 |
Merge into: | lp:launchpad |
Diff against target: |
74 lines (+19/-4) 3 files modified
lib/canonical/launchpad/security.py (+10/-0) lib/lp/services/worlddata/interfaces/language.py (+6/-1) lib/lp/services/worlddata/stories/webservice/xx-language.txt (+3/-3) |
To merge this branch: | bzr merge lp:~adiroiban/launchpad/bug-561355 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Aaron Bentley (community) | Approve | ||
Review via email: mp+23249@code.launchpad.net |
Commit message
Allow all users, including anonymous users to read ILanguageSet and ILanguage using the webservices.
Description of the change
= Bug 561355 =
The ILanguage and ILanguageSet are not visible to anonymous users.
== Proposed fix ==
Add adapters inheriting AnonymousAuthor
== Pre-implementation notes ==
I talked with Danilo and the confirmed that those attributes should be visible by anonymous users.
== Implementation details ==
I have also changed the general description for ILanguageSet to inform users that by default, only visible languages are returned.
== Tests ==
lp-test -t xx-language
== Demo and Q/A ==
Make sure you are not logged in.
Go to: https:/
You should see the languages, together with their content.
in launchapdlib
>>> launchpad = Launchpad.
>>> langs = launchpad.languages
>>> for lang in langs[:10]:
... print lang.english_name
...
Abkhazian
Acehnese
Acoli
Adangme
Adyghe; Adygei
Afar
Afrihili
Afrikaans
Akan
Albanian
>>>
= Launchpad lint =
Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.
Linting changed files:
lib/lp/
== Pylint notices ==
lib/lp/
18: [F0401] Unable to import 'lazr.enum' (No module named lazr.enum)
20: [F0401] Unable to import 'lazr.restful.
This looks reasonable, aside from the grammar of the docstring.
I suggest: "The standard get method will return only the visible languages.
If you want to access all languages known to Launchpad, use
the getAllLanguages method."