Exemplo n.º 1
0
    def run(self):
        QueueItem.run(self)

        try:
            sickrage.LOGGER.info("Beginning daily search for new episodes")
            foundResults = searchForNeededEpisodes()

            if not len(foundResults):
                sickrage.LOGGER.info("No needed episodes found")
            else:
                for result in foundResults:
                    # just use the first result for now
                    sickrage.LOGGER.info("Downloading " + result.name + " from " + result.provider.name)
                    self.success = snatchEpisode(result)

                    # give the CPU a break
                    gen.sleep(cpu_presets[sickrage.CPU_PRESET])

            QueueItem.finish(self)
        except Exception:
            sickrage.LOGGER.debug(traceback.format_exc())

        if self.success is None:
            self.success = False

        self.finish()
Exemplo n.º 2
0
    def run(self):
        QueueItem.run(self)

        try:
            sickrage.LOGGER.info("Beginning daily search for new episodes")
            foundResults = searchForNeededEpisodes()

            if not len(foundResults):
                sickrage.LOGGER.info("No needed episodes found")
            else:
                for result in foundResults:
                    # just use the first result for now
                    sickrage.LOGGER.info("Downloading " + result.name +
                                         " from " + result.provider.name)
                    self.success = snatchEpisode(result)

                    # give the CPU a break
                    gen.sleep(cpu_presets[sickrage.CPU_PRESET])

            QueueItem.finish(self)
        except Exception:
            sickrage.LOGGER.debug(traceback.format_exc())

        if self.success is None:
            self.success = False

        self.finish()