Closed Bug 2014493 Opened 5 days ago Closed 11 hours ago

Re-use network error messages from m-c in felt

Categories

(Firefox Enterprise :: Client, task, P1)

x86_64
macOS

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: janika, Unassigned)

References

(Blocks 2 open bugs)

Details

(Whiteboard: [size=1])

We already have localised network error messages (see https://searchfox.org/firefox-main/source/browser/locales/en-US/chrome/overrides/appstrings.properties) and a switch case that maps status to string id: https://searchfox.org/firefox-main/rev/ab8a90487516e59b3ac3b5cc503d024a2be8ea80/docshell/base/nsDocShell.cpp#3435-3753. We should outfactor that logic and re-use it when we have console connection errors and surface that in the felt window instead of duplicating and translating our own small set of network error messages.

Severity: -- → S1
Priority: -- → P1
Whiteboard: [size=1]

(In reply to Janika Neuberger [:janika] from comment #0)

We already have localised network error messages (see https://searchfox.org/firefox-main/source/browser/locales/en-US/chrome/overrides/appstrings.properties) and a switch case that maps status to string id: https://searchfox.org/firefox-main/rev/ab8a90487516e59b3ac3b5cc503d024a2be8ea80/docshell/base/nsDocShell.cpp#3435-3753. We should outfactor that logic and re-use it when we have console connection errors and surface that in the felt window instead of duplicating and translating our own small set of network error messages.

Console connection error should use Fluent, not legacy properties, so I'm not sure there is much to factor from there

Conversation on this continues on GitHub: https://github.com/mozilla/enterprise-firefox/pull/358

(In reply to Janika Neuberger [:janika] from comment #2)

Conversation on this continues on GitHub: https://github.com/mozilla/enterprise-firefox/pull/358

Latest pushes uses Services.string so there is still some refactoring that could be done in mapping errors code that nsDocShell::DisplayLoadError does and we have to re-do, but at least strings are re-used on the PR now.

Blocks: 2015092

See comment 3.

Status: NEW → RESOLVED
Closed: 11 hours ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.