def bisect_nightlies()

in mozregression/main.py [0:0]


    def bisect_nightlies(self):
        good_date, bad_date = self.options.good, self.options.bad
        handler = NightlyHandler(
            find_fix=self.options.find_fix,
            ensure_good_and_bad=self.options.mode != "no-first-check",
        )
        result = self._do_bisect(handler, good_date, bad_date)
        if result == Bisection.FINISHED:
            LOG.info("Got as far as we can go bisecting nightlies...")
            handler.print_range()
            if self.fetch_config.can_go_integration():
                LOG.info("Switching bisection method to taskcluster")
                self.fetch_config.set_repo(self.fetch_config.get_nightly_repo(handler.bad_date))
                return self._bisect_integration(
                    handler.good_revision, handler.bad_revision, expand=DEFAULT_EXPAND
                )
        elif result == Bisection.USER_EXIT:
            self._print_resume_info(handler)
        else:
            # NO_DATA
            LOG.info(
                "Unable to get valid builds within the given"
                " range. You should try to launch mozregression"
                " again with a larger date range."
            )
            return 1
        return 0