Deprecating DTD for localization in Firefox UI

Zibi Braniecki (Gandalf) zbraniecki at mozilla.com
Thu Oct 24 19:09:47 UTC 2019


Hi all,

tl;dr: Please use Fluent instead of adding or changing existing DTD strings.

== DTD and Fluent ==

DTD has been used as the core localization format and API inside of Firefox
since the dawn of Mozilla, allowing us to localize our XUL and other XML
files.

Unfortunately, DTD comes with a set of quite painful limitations, including
the so called Yellow Screen of Death which causes a crash at startup and
requires a complicated manual process by each user to recover. We’ve
recently been affected by this on beta [1].

For a couple years now, we’ve been working on a replacement for DTD - a new
localization system called Fluent [2] which (among other things) addresses
the shortcomings of DTD.

== Deprecating DTD for localization in browser chrome ==

Now that Fluent meets the performance requirements to replace DTD, we would
like to deprecate the DTD file format as a localization mechanism in
Firefox.

Please could you:

   1.

   Avoid introducing any new DTD strings in mozilla-central.
   2.

   If existing DTD strings would need to be changed, migrate them to Fluent
   [3] instead of updating the message identifier in DTD.


There are a few small areas where integrating Fluent is not entirely
trivial (most notably UA widgets) and those will be exempted from the
deprecation.

In case you believe there are technical reasons to continue using DTD in
your project, please consult fluent-reviewers group [4], which has been
recently extended with additions of Jared Wein, Gijs Kruitbosch and Edward
Lee. They can be reached in #fluent on Slack or fluent-reviewers on
phabricator.

The change does not affect release or beta uplifts, since we don’t change
strings in those. ESR uplifts will be exempted from the deprecation.

== Dashboard ==

In order to visualize our progress, we recently updated our dashboard:
https://arewefluentyet.com/

The new version introduces three milestones:

M1 - Removal of DTD from browser.xhtml - addresses Yellow Screen of Death
[5]

M2 - Migration of the startup path to Fluent [6]

Mx - Migration of the whole mozilla-central to Fluent [7]

Additional milestones may be added as we identify them.

Each one of these milestones will enable a set of new features for Firefox,
and deprecating DTD for localization is aiming to help us achieve them
sooner.


If you have any questions, let me know!

Cheers,

zb.

[1]
https://www.reddit.com/r/firefox/comments/d5wq0z/firefox_crashes_on_browser_startup_and_flashes/


[2] https://firefox-source-docs.mozilla.org/intl/l10n/l10n/index.html

[3]
https://firefox-source-docs.mozilla.org/intl/l10n/l10n/fluent_migrations.html

[4] fluent-reviewers group  (#fluent on Slack):

   -

   Francesco Lodolo
   -

   Jared Wein
   -

   Gijs Kruitbosch
   -

   Edward Lee
   -

   Axel Hecht
   -

   Staś Małolepszy
   -

   Zibi Braniecki

[5] https://bugzilla.mozilla.org/show_bug.cgi?id=1579477

[6] https://bugzilla.mozilla.org/show_bug.cgi?id=1501881

[7] https://bugzilla.mozilla.org/show_bug.cgi?id=1581212
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/firefox-dev/attachments/20191024/1bf43e72/attachment.html>


More information about the firefox-dev mailing list