From be7e11956cb744c0aa64861fe1248c53c742305b Mon Sep 17 00:00:00 2001 From: Josef Skladanka Date: May 24 2012 11:37:48 +0000 Subject: t420 - Some builds were tested many times over The problem was, that in a situation, where 'untagged_builds' were stored from previous run, and no new updates_candidate builds were in koji, then the prevtime from the 'untagged_builds' got stored, and sent the 'where should i start to check for new builds' date to the past. --- diff --git a/watchers/koji-bodhi/watcher.py b/watchers/koji-bodhi/watcher.py index 25c7c30..f5bb513 100755 --- a/watchers/koji-bodhi/watcher.py +++ b/watchers/koji-bodhi/watcher.py @@ -222,13 +222,6 @@ class KojiWatcher(object): logging.info(" Fetching builds since: %s", prevtime) builds = self.session.listBuilds(completeAfter=prevtime) - try: - builds += self.prevtimes['untagged_builds'] # untagged builds from previous run - logging.info(" Adding previously stored untagged builds") - except KeyError: - # no previously stored undagged builds, pass - logging.info(" No previously stored untagged builds") - pass logging.info(" Sorting according to completion_ts") builds.sort(key = lambda pkg: pkg['completion_ts']) @@ -238,6 +231,14 @@ class KojiWatcher(object): logging.info(" No new builds since last check") pass + try: + builds += self.prevtimes['untagged_builds'] # untagged builds from previous run + logging.info(" Adding previously stored untagged builds") + except KeyError: + # no previously stored undagged builds, pass + logging.info(" No previously stored untagged builds") + pass + logging.info(" Assorting according to tags") self.session.multicall = True for build in builds: