Closed Bug 1469696 Opened 6 years ago Closed 6 years ago

Support installing official language packs from AMO

Categories

(Firefox :: Settings UI, enhancement, P1)

enhancement

Tracking

()

RESOLVED FIXED
Firefox 64
Tracking Status
firefox64 --- fixed

People

(Reporter: mstriemer, Assigned: mstriemer)

References

(Blocks 2 open bugs)

Details

Attachments

(7 files, 6 obsolete files)

46 bytes, text/x-phabricator-request
aswan
: review+
jaws
: review+
Details | Review
46 bytes, text/x-phabricator-request
zbraniecki
: review+
jaws
: review+
aswan
: review+
Details | Review
46 bytes, text/x-phabricator-request
jaws
: review+
Details | Review
46 bytes, text/x-phabricator-request
flod
: review+
jaws
: review+
Details | Review
46 bytes, text/x-phabricator-request
aswan
: review+
jaws
: review+
Details | Review
46 bytes, text/x-phabricator-request
flod
: review+
jaws
: review+
Details | Review
145.63 KB, image/png
Details
In the configure dialog from bug 1469688 a user should be able to see a list of available language packs in a dropdown, populated from AMO. Selecting one of these languages and clicking "Add" should download the language pack and add it to the list for the user to select.
Priority: P3 → P1
Attached file language-tools.json (obsolete) —
Here's a mock response that points to some nightly langpack builds. To test this you'll need to set the following prefs:

  intl.multilingual.enabled;true
  extensions.langpacks.signatures.required;false
  extensions.getAddons.langpacks.url;file:///path/to/language-tools.json

That should allow you to list and install language packs. Note there is an issue currently with the formatting of the ja-JP locale (at least on mac). I will file a bug for that as it appears to be unrelated.
Attachment #9010373 - Attachment is obsolete: true
Attachment #9010374 - Attachment is obsolete: true
Attachment #9010375 - Attachment is obsolete: true
Attachment #9010376 - Attachment is obsolete: true
Attachment #9010377 - Attachment is obsolete: true
Comment on attachment 9010413 [details]
Bug 1469696 - Part 2: Allow installing langpacks from AMO in prefs r?aswan!,jaws!,zbraniecki

Zibi Braniecki [:gandalf][:zibi] has approved the revision.
Attachment #9010413 - Flags: review+
Michelle, can you confirm if these strings work?

browser-languages-installed-label = Installed languages
browser-languages-available-label = Available languages

See also https://docs.google.com/a/mozilla.com/document/d/1zqBRFVHKVeRI40JJtTNB1X34oE1WlhZyFKMFvQ-n-Ak/edit?disco=uiAAAACIicSq4
Flags: needinfo?(mheubusch)
Comment on attachment 9010414 [details]
Bug 1469696 - Part 3: Allow searching for languages from dialog r?jaws!

Jared Wein [:jaws] (please needinfo? me) has approved the revision.
Attachment #9010414 - Flags: review+
Comment on attachment 9010416 [details]
Bug 1469696 - Part 5: Test listing and installing AMO langpacks r?aswan,jaws!

Jared Wein [:jaws] (please needinfo? me) has approved the revision.
Attachment #9010416 - Flags: review+
Comment on attachment 9010416 [details]
Bug 1469696 - Part 5: Test listing and installing AMO langpacks r?aswan,jaws!

Andrew Swan [:aswan] has approved the revision.
Attachment #9010416 - Flags: review+
Comment on attachment 9010416 [details]
Bug 1469696 - Part 5: Test listing and installing AMO langpacks r?aswan,jaws!

Jared Wein [:jaws] (please needinfo? me) has been removed from the revision.
Attachment #9010416 - Flags: review+
Comment on attachment 9010416 [details]
Bug 1469696 - Part 5: Test listing and installing AMO langpacks r?aswan,jaws!

Jared Wein [:jaws] (please needinfo? me) has approved the revision.
Attachment #9010416 - Flags: review+
Attachment #9010412 - Attachment description: Bug 1469696 - Part 1: Use real langpacks in multilingual tests r?aswan → Bug 1469696 - Part 1: Use stub langpacks in multilingual tests r?aswan
Comment on attachment 9010412 [details]
Bug 1469696 - Part 1: Use stub langpacks in multilingual tests r?aswan!

Andrew Swan [:aswan] has approved the revision.
Attachment #9010412 - Flags: review+
Attachment #9010412 - Attachment description: Bug 1469696 - Part 1: Use stub langpacks in multilingual tests r?aswan → Bug 1469696 - Part 1: Use stub langpacks in multilingual tests r?aswan!
Attachment #9010413 - Attachment description: Bug 1469696 - Part 2: Allow installing langpacks from AMO in prefs r?aswan,jaws → Bug 1469696 - Part 2: Allow installing langpacks from AMO in prefs r?aswan!,jaws!,zbraniecki
Attachment #9010414 - Attachment description: Bug 1469696 - Part 3: Allow searching for languages from dialog r?jaws → Bug 1469696 - Part 3: Allow searching for languages from dialog r?jaws!
Attachment #9010415 - Attachment description: Bug 1469696 - Part 4: Separate installed and available langpacks r?jaws → Bug 1469696 - Part 4: Separate installed and available langpacks r?jaws!
Attachment #9010416 - Attachment description: Bug 1469696 - Part 5: Test listing and installing AMO langpacks r?aswan,jaws → Bug 1469696 - Part 5: Test listing and installing AMO langpacks r?aswan,jaws!
Comment on attachment 9010415 [details]
Bug 1469696 - Part 4: Separate installed and available langpacks r?jaws!

Francesco Lodolo [:flod] has approved the revision.
Attachment #9010415 - Flags: review+
Comment on attachment 9010412 [details]
Bug 1469696 - Part 1: Use stub langpacks in multilingual tests r?aswan!

Jared Wein [:jaws] (please needinfo? me) has approved the revision.
Attachment #9010412 - Flags: review+
Comment on attachment 9010413 [details]
Bug 1469696 - Part 2: Allow installing langpacks from AMO in prefs r?aswan!,jaws!,zbraniecki

Jared Wein [:jaws] (please needinfo? me) has approved the revision.
Attachment #9010413 - Flags: review+
Comment on attachment 9010415 [details]
Bug 1469696 - Part 4: Separate installed and available langpacks r?jaws!

Jared Wein [:jaws] (please needinfo? me) has approved the revision.
Attachment #9010415 - Flags: review+
Comment on attachment 9010413 [details]
Bug 1469696 - Part 2: Allow installing langpacks from AMO in prefs r?aswan!,jaws!,zbraniecki

Andrew Swan [:aswan] has approved the revision.
Attachment #9010413 - Flags: review+
Here's a screenshot with the updated error message.
Comment on attachment 9012996 [details]
Bug 1469696 - Part 6: Update warning message, limit width r?jaws!

Francesco Lodolo [:flod] has approved the revision.
Attachment #9012996 - Flags: review+
Comment on attachment 9012996 [details]
Bug 1469696 - Part 6: Update warning message, limit width r?jaws!

Jared Wein [:jaws] (please needinfo? me) has approved the revision.
Attachment #9012996 - Flags: review+
Blocks: 1495804
Pushed by francesco.lodolo@mozillaitalia.org:
https://hg.mozilla.org/integration/autoland/rev/263bd17c558e
Part 1: Use stub langpacks in multilingual tests r=aswan,jaws
https://hg.mozilla.org/integration/autoland/rev/31c94d7845b7
Part 2: Allow installing langpacks from AMO in prefs r=flod,aswan,zbraniecki,jaws
https://hg.mozilla.org/integration/autoland/rev/10b8ab80417d
Part 3: Allow searching for languages from dialog r=jaws
https://hg.mozilla.org/integration/autoland/rev/4973d5d699c5
Part 4: Separate installed and available langpacks r=flod,jaws
https://hg.mozilla.org/integration/autoland/rev/54abaf608a60
Part 5: Test listing and installing AMO langpacks r=aswan,jaws
https://hg.mozilla.org/integration/autoland/rev/5b0ef00bdd7c
Part 6: Update warning message, limit width r=flod,jaws
I've setup a test server that can be used to test this on Nightly. It will use the most recent l10n build it can find so the langpack that it installs _should_ (hopefully, maybe) work just fine.

You can test this by setting the following prefs:

  intl.multilingual.enabled=true
  extensions.langpacks.signatures.required=false
  extensions.getAddons.langpacks.url=https://mock-amo-language-tools.glitch.me/
Flags: needinfo?(mheubusch)
Attachment #9010385 - Attachment is obsolete: true
Any particular reason why your using a "smart" quote here?
https://hg.mozilla.org/mozilla-central/rev/5b0ef00bdd7c#l3.14
  "can’t"
Flags: needinfo?(mstriemer)
(In reply to Jorg K (GMT+1) from comment #32)
> Any particular reason why your using a "smart" quote here?
> https://hg.mozilla.org/mozilla-central/rev/5b0ef00bdd7c#l3.14
>   "can’t"

Unless I'm misunderstanding "smart quote": that's a proper apostrophe, and that's how they're supposed to be written across Firefox messages, to the point that there are tests enforcing them.
https://searchfox.org/mozilla-central/source/browser/base/content/test/static/browser_misused_characters_in_strings.js
Flags: needinfo?(mstriemer)
> .label = Don't Autoplay

That's (sadly) a side effect of not having those tests for Fluent files, and it should be fixed. Comments are not relevant, they can use straight quotes (single or double).
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: