[game-data-packager] 03/10: better_version: sort checks to avoid priting false positive error

Simon McVittie smcv at debian.org
Fri Jan 23 01:05:35 UTC 2015


This is an automated email from the git hooks/post-receive script.

smcv pushed a commit to branch master
in repository game-data-packager.

commit 87a39790de7f264141ef286a69957232388fa9dc
Author: Alexandre Detiste <alexandre.detiste at gmail.com>
Date:   Thu Jan 22 21:55:29 2015 +0100

    better_version: sort checks to avoid priting false positive error
    
    the checking of 'conflics:' remain as a safety net
---
 game_data_packager/__init__.py | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/game_data_packager/__init__.py b/game_data_packager/__init__.py
index 76418a5..35d4e29 100644
--- a/game_data_packager/__init__.py
+++ b/game_data_packager/__init__.py
@@ -2037,6 +2037,12 @@ class GameData(object):
         ready = set()
 
         for package in possible:
+            if (package.better_version
+                and self.packages[package.better_version] in possible):
+                  logger.debug('will not produce "%s" because better version '
+                     '"%s" is also avaible', package.name, package.better_version)
+                  continue
+
             abort = False
             if not build_demos:
                 for demo_for in package.demo_for:
@@ -2053,12 +2059,6 @@ class GameData(object):
                        'conflicts with "%s"', package.name, previous.name)
                     abort = True
 
-            if (package.better_version
-                and self.packages[package.better_version] in possible):
-                  logger.debug('will not produce "%s" because better version '
-                     '"%s" is also avaible', package.name, package.better_version)
-                  abort = True
-
             if abort:
                 continue
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/game-data-packager.git



More information about the Pkg-games-commits mailing list