Bug 1359988 - Remove retrieve_b2g_device(); r?mshal draft
authorGregory Szorc <gps@mozilla.com>
Wed, 26 Apr 2017 13:59:36 -0700
changeset 568996 591bbcb05a9ca0cb981820f84ee22d50356fd9e7
parent 568995 6847d44001c390b0e166b7825db13d766da8969d
child 626084 1e7461e7aebe4ac272cc4cf8d9ead9bcf1a0f5c5
push id56042
push userbmo:gps@mozilla.com
push dateWed, 26 Apr 2017 21:02:59 +0000
reviewersmshal
bugs1359988
milestone55.0a1
Bug 1359988 - Remove retrieve_b2g_device(); r?mshal There appear to be no in-tree users of this function and it references "b2g." I'm pretty sure it is dead code. MozReview-Commit-ID: EHHRQ2iqQoP
testing/mozharness/mozharness/mozilla/testing/mozpool.py
--- a/testing/mozharness/mozharness/mozilla/testing/mozpool.py
+++ b/testing/mozharness/mozharness/mozilla/testing/mozpool.py
@@ -48,37 +48,16 @@ class MozpoolMixin(object):
                 self.MozpoolException = MozpoolException
                 self.MozpoolConflictException = MozpoolConflictException
                 self.mozpool_handler = MozpoolHandler(self.mozpool_api_url, log_obj=self)
             except ImportError, e:
                 self.fatal("Can't instantiate MozpoolHandler until mozpoolclient python "
                            "package is installed! (VirtualenvMixin?): \n%s" % str(e))
             return self.mozpool_handler
 
-    def retrieve_b2g_device(self, b2gbase):
-        mph = self.query_mozpool_handler(self.mozpool_device)
-        for retry in self._retry_sleep(
-                error_message="INFRA-ERROR: Could not request device '%s'" % self.mozpool_device,
-                tbpl_status=TBPL_EXCEPTION):
-            try:
-                image = 'b2g'
-                duration = 4 * 60 * 60 # request valid for 14400 seconds == 4 hours
-                response = mph.request_device(self.mozpool_device, image, assignee=self.mozpool_assignee, \
-                               b2gbase=b2gbase, pxe_config=None, duration=duration)
-                break
-            except self.MozpoolConflictException:
-                self.warning("Device unavailable. Retry#%i.." % retry)
-            except self.MozpoolException, e:
-                self.buildbot_status(TBPL_RETRY)
-                self.fatal("We could not request the device: %s" % str(e))
-
-        self.request_url = response['request']['url']
-        self.info("Got request, url=%s" % self.request_url)
-        self._wait_for_request_ready()
-
     def retrieve_android_device(self, b2gbase):
         mph = self.query_mozpool_handler(self.mozpool_device)
         for retry in self._retry_sleep(
                 error_message="INFRA-ERROR: Could not request device '%s'" % self.mozpool_device,
                 tbpl_status=TBPL_RETRY):
             try:
                 image = 'panda-android-4.0.4_v3.3'
                 duration = 4 * 60 * 60 # request valid for 14400 seconds == 4 hours