Bug 1415432 - .ftl files repackaged multiple times. r=glandium
authorZibi Braniecki <zbraniecki@mozilla.com>
Tue, 07 Nov 2017 22:16:16 -0800
changeset 390808 969c788d78b3f3b7515a83a268e2afe4a5c76a58
parent 390807 3b80b33600a887946ee826581b230a46560c2a82
child 390809 34e1dd628fb3b9618c23c1c81a0821c764c01d62
push id32845
push userarchaeopteryx@coole-files.de
push dateWed, 08 Nov 2017 22:08:47 +0000
treeherdermozilla-central@c10cf7082a9b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs1415432
milestone58.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1415432 - .ftl files repackaged multiple times. r=glandium
python/mozbuild/mozpack/packager/l10n.py
--- a/python/mozbuild/mozpack/packager/l10n.py
+++ b/python/mozbuild/mozpack/packager/l10n.py
@@ -215,17 +215,18 @@ def _repack(app_finder, l10n_finder, cop
             for p, f in l10n_finder.find(mozpath.join(base, pattern)):
                 if not formatter.contains(p):
                     formatter.add(p, f)
 
     # Resources in `localization` directories are packaged from the source and then
     # if localized versions are present in the l10n dir, we package them as well
     # keeping the source dir resources as a runtime fallback.
     for p, f in l10n_finder.find('**/localization'):
-        formatter.add(p, f)
+        if not formatter.contains(p):
+            formatter.add(p, f)
 
     # Transplant jar preloading information.
     for path, log in app_finder.jarlogs.iteritems():
         assert isinstance(copier[path], Jarrer)
         copier[path].preload([l.replace(locale, l10n_locale) for l in log])
 
 
 def repack(source, l10n, extra_l10n={}, non_resources=[], non_chrome=set()):