Closed Bug 1605489 Opened 1 year ago Closed 1 year ago

Errors when enabling spellcheck in a text box

Categories

(Core :: Internationalization, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla73
Tracking Status
firefox73 --- fixed

People

(Reporter: Paenglab, Assigned: zbraniecki)

Details

Attachments

(1 file)

STR: Open https://searchfox.org/ then in one of the two text fields right click and tick Check Spelling on. Now right click again (the Languages menuitem should be shown now) and the errors appear.

Errors: two times
[Exception... "Component returned failure code: 0x80520012 (NS_ERROR_FILE_NOT_FOUND) [nsIXPCComponents_Utils.readUTF8URI]" nsresult: "0x80520012 (NS_ERROR_FILE_NOT_FOUND)" location: "JS frame :: resource://gre/modules/L10nRegistry.jsm :: this.L10nRegistry.loadSync :: line 759" data: no] L10nRegistry.jsm:759

The source is:

  • We try to load languageNames.ftl and regionNames.ftl from browser omni.ja, both fail, producing those errors
  • then we try from toolkit omni.ja, both succeed.

The source is mozIntl, and the API is going to be replaced with https://github.com/tc39/proposal-intl-displaynames (see bug 1557727).

Until then, we need to handle that in a sync fashion, which is what we do with this API. I'm open to suggestions on how to fetch the files without producing those errors when files are missing.

Can we just catch NS_ERROR_FILE_NOT_FOUND and not log it to the console?

Component: General → Internationalization
Flags: needinfo?(gandalf)
Product: Toolkit → Core

Yup! 🤦

Flags: needinfo?(gandalf)
Assignee: nobody → gandalf
Status: NEW → ASSIGNED
Pushed by zbraniecki@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/509cd3b3ec22
Do not report missing files from L10nRegistry.loadSync to the console. r=mossop
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla73
QA Whiteboard: [qa-73b-p2]
You need to log in before you can comment on or make changes to this bug.