Open Bug 1764081 Opened 2 years ago Updated 1 year ago

Customize toolbar view does not live switch languages

Categories

(Core :: Internationalization, defect)

defect

Tracking

()

Tracking Status
firefox101 --- affected

People

(Reporter: obotisan, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 obsolete file)

Affected versions

  • Firefox 100

Affected platforms

  • Windows 10 x64
  • Ubuntu 20.04 x64
  • macOS 10.15

Preconditions

  • Customize the Toolbar (add Downloads, Bookmarks, Sidebar etc. to the Toolbar.
  • Have the Bookmark bar always displayed.

Steps to reproduce

  1. Open firefox using a locale that is different from the OS language.
  2. Go to about:preferences#general and click on "Set Alternatives..."
  3. Add a language.
  4. Add another language or change back to the original language.
  5. Observe the App menu.

Expected result

  • All the texts are translated.

Actual result

  • Some of the strings remain in the language selected at step 3.

Notes

  • This issue affects context menus from Library window, title from ETP panel, some elements from the Bookmark dropdown, tooltips that appear if the elements from the Toolbar are hovered, "Getting started..." hyperlink from the Bookmark bar etc.

I will lower the severity for this issue, but I suggest to give it a higher priority because it is a troublesome one.

Severity: S2 → S3
Has STR: --- → yes

Hi! It seems that there’s no need to change the language twice in order to hit this bug. Certain strings remained untranslated on a latest Beta 100.0b (FR build), after changing the primary language into:

  • Deutsch
  • Italiano
  • Espanol

For example, some of the places where the strings are not translated can be seen in:

It could happen with other major languages, these have been the ones that have shown problems so far.

Greg, does it seem that the issue described here has the same root cause as this bug? We can file a separate issue, otherwise.

Flags: needinfo?(gtatum)

I'm working on one of the root-cause issues in Bug 1764802, but there are frequently other bits of caching sprinkled across these pieces of UI. So I suspect they could use separate bugs filed.

Flags: needinfo?(gtatum)

Thanks for checking! I've filed a separate bug for the issue mentioned in my previous comment (Bug 1765486).

Summary: If the language is changed twice some of the strings are not translated → Customize toolbar view does not live switch languages

https://searchfox.org/mozilla-central/rev/2fd70a667e6f89a9ec6622ecb302b1ab48e4a062/browser/components/customizableui/CustomizeMode.jsm#133

This mutation observer seems to be broken. This fix should include a test using the new testing infrastructure proposed in Bug 1761835.

I updated the summary of this bug to be more precise about this specific issue. The workaround for it is to restart the browser, and it will be in the new language.

This fixes the Fluent live switching, but does not fix the elements
defined by properties files.

Assignee: nobody → gtatum
Status: NEW → ASSIGNED

FYI: Product and Engineering agree that this bug does not need to fixed in order for Live Language Switching to ship in Fx 100.

Pushed by gtatum@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/5029c82449ff
Fix Fluent locale switching in CustomizeUI; r=platform-i18n-reviewers,dminor

Backed out for causing mochitest failures on browser_locale_changes.js

  • Backout link
  • Push with failures
  • Failure Log
  • Failure line: TEST-UNEXPECTED-FAIL | browser/components/customizableui/test/browser_locale_changes.js | Uncaught exception in test - Wait for the accented translation to happen. - timed out after 50 tries.
Flags: needinfo?(gtatum)

There's some kind of race condition here that I can trigger through --verify.

Flags: needinfo?(gtatum)

It's not intermittent. It fails when run two times in a row, as the translations aren't re-triggered. The logic applied here is confusing me and I'm having trouble figuring out where to correctly apply the translations.

Attachment #9273442 - Attachment is obsolete: true
Assignee: gtatum → nobody
Status: ASSIGNED → NEW
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: