Bug 1630282 - Not all locales have the same number of map service prefs. r=rjl
authorIan Neal <iann_cvs@blueyonder.co.uk>
Wed, 15 Apr 2020 15:51:27 +0100
changeset 38888 0665e9d6b9ecba9d68c5868324b4aa4f2e9f3670
parent 38887 62453d8cdbb795a82b49d3d1bd2c99b9fecf7c3a
child 38889 d78ead15b14ff1ce22eee4c883cf9ef8b3a8e2d7
push id401
push userclokep@gmail.com
push dateMon, 01 Jun 2020 20:41:59 +0000
reviewersrjl
bugs1630282
Bug 1630282 - Not all locales have the same number of map service prefs. r=rjl
mail/locales/filter.py
mail/locales/l10n.toml
suite/locales/filter.py
suite/locales/l10n.toml
--- a/mail/locales/filter.py
+++ b/mail/locales/filter.py
@@ -14,12 +14,13 @@ def test(mod, path, entity=None):
   if mod == "mail" and path == "defines.inc" and \
      entity == "MOZ_LANGPACK_CONTRIBUTORS":
     return "ignore"
   # ignore dictionaries
   if mod == "extensions/spellcheck":
     return "ignore"
 
   if path == "chrome/messenger-region/region.properties":
-    return ("ignore" if (re.match(r"browser\.search\.order\.[1-9]", entity))
+    return ("ignore" if (re.match(r"browser\.search\.order\.[1-9]", entity) or
+                         re.match(r"mail\.addr_book\.mapit_url\.[1-5]", entity))
             else "error")
 
   return "error"
--- a/mail/locales/l10n.toml
+++ b/mail/locales/l10n.toml
@@ -127,8 +127,14 @@ locales = [
     ]
     action = "ignore"
 
 # search prefs don't have the same number for all locales
 [[filters]]
     path = "{l}mail/chrome/messenger-region/region.properties"
     key = "re:browser\\.search\\.order\\.[1-9].*"
     action = "ignore"
+
+# map service prefs don't have the same number for all locales
+[[filters]]
+    path = "{l}mail/chrome/messenger-region/region.properties"
+    key = "re:mail\\.addr_book\\.mapit_url\\.[1-5].*"
+    action = "ignore"
--- a/suite/locales/filter.py
+++ b/suite/locales/filter.py
@@ -32,15 +32,19 @@ def test(mod, path, entity=None):
   if path == "defines.inc":
     return ("ignore" if (entity == "MOZ_LANGPACK_CONTRIBUTORS")
             else "error")
 
   if path == "chrome/common/region.properties":
     return ("ignore" if (re.match(r"browser\.search\.order\.[1-9]", entity))
             else "error")
 
+  if path == "chrome/mailnews/region.properties":
+    return ("ignore" if (re.match(r"mail\.addr_book\.mapit_url\.[1-5]", entity))
+            else "error")
+
   if path != "chrome/browser/region.properties":
     # only region.properties exceptions remain, compare all others
     return "error"
 
   return ("ignore"
           if (re.match(r"browser\.contentHandlers\.types\.[0-5]", entity))
           else "error")
--- a/suite/locales/l10n.toml
+++ b/suite/locales/l10n.toml
@@ -94,16 +94,22 @@ locales = [
     action = "ignore"
 
 # content handler prefs don't have the same number for all locales
 [[filters]]
     path = "{l}suite/chrome/browser/region.properties"
     key = "re:browser\\.contentHandlers\\.types\\.[0-5].*"
     action = "ignore"
 
+# map service prefs don't have the same number for all locales
+[[filters]]
+    path = "{l}suite/chrome/mailnews/region.properties"
+    key = "re:mail\\.addr_book\\.mapit_url\\.[1-5].*"
+    action = "ignore"
+
 # search plugins are different per locale, ignore file difference
 [[filters]]
     path = "{l}suite/searchplugins/*.xml"
     action = "ignore"
 
 # extra data and help images are optional
 [[filters]]
     path = [