Bug 1344202 - uptake monitoring better handling absence of partials. r=rail a=release DONTBUILD draft
authorMihai Tabara <mtabara@mozilla.com>
Thu, 09 Mar 2017 16:52:11 +0000
changeset 495982 1c6a9515a7cc5fd1b5c3482a6806bcc69bbbb5dd
parent 495841 c40ca7a1bdd93632c6bdc5e23bd33d984d508b19
child 548515 647b1d050dcd82d9cefbedc5948ffd0e88bd045b
push id48493
push userbmo:mtabara@mozilla.com
push dateThu, 09 Mar 2017 17:18:16 +0000
reviewersrail, release
bugs1344202
milestone55.0a1
Bug 1344202 - uptake monitoring better handling absence of partials. r=rail a=release DONTBUILD MozReview-Commit-ID: 9nj7qe5hWa9
testing/mozharness/scripts/release/uptake_monitoring.py
--- a/testing/mozharness/scripts/release/uptake_monitoring.py
+++ b/testing/mozharness/scripts/release/uptake_monitoring.py
@@ -72,18 +72,19 @@ class UptakeMonitoring(BaseScript, Virtu
         props = self.buildbot_config["properties"]
         for prop in ['tuxedo_server_url', 'version']:
             if props.get(prop):
                 self.info("Overriding %s with %s" % (prop, props[prop]))
                 self.config[prop] = props.get(prop)
             else:
                 self.warning("%s could not be found within buildprops" % prop)
                 return
-        partials = [v.strip() for v in props["partial_versions"].split(",")]
-        self.config["partial_versions"] = [v.split("build")[0] for v in partials]
+        if props.get('partial_versions'):
+            partials = [v.strip() for v in props["partial_versions"].split(",")]
+            self.config["partial_versions"] = [v.split("build")[0] for v in partials]
         self.config["platforms"] = [p.strip() for p in
                                     props["platforms"].split(",")]
 
     def _get_product_uptake(self, tuxedo_server_url, auth,
                             related_product, os):
         from redo import retry
         import requests
 
@@ -131,18 +132,18 @@ class UptakeMonitoring(BaseScript, Virtu
                 paths_platforms = set(info["paths"].keys())
                 platforms = enUS_platforms.intersection(paths_platforms)
 
                 for platform in platforms:
                     bouncer_platform = info["paths"].get(platform).get('bouncer-platform')
                     dl.append(self._get_product_uptake(tuxedo_server_url, auth,
                                                        related_product, bouncer_platform))
         # handle the partials as well
-        prev_versions = self.config["partial_versions"]
-        for product, info in self.config["partials"].iteritems():
+        prev_versions = self.config.get("partial_versions", [])
+        for product, info in self.config.get("partials", {}).iteritems():
             if info.get("check_uptake"):
                 product_template = info["product-name"]
                 for prev_version in prev_versions:
                     subs = {
                         "version": version,
                         "prev_version": prev_version
                     }
                     related_product = product_template % subs