[game-data-packager] 01/01: look_for_engines: handle blakestone.yaml correctly

Alexandre Detiste detiste-guest at moszumanska.debian.org
Mon Jul 13 11:40:04 UTC 2015


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

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

commit 5c2e0d89036a7fda0e5488aa3c4b8a285aab703a
Author: Alexandre Detiste <alexandre.detiste at gmail.com>
Date:   Mon Jul 13 13:39:23 2015 +0200

    look_for_engines: handle blakestone.yaml correctly
---
 game_data_packager/__init__.py | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/game_data_packager/__init__.py b/game_data_packager/__init__.py
index a621786..34c46cc 100644
--- a/game_data_packager/__init__.py
+++ b/game_data_packager/__init__.py
@@ -2361,14 +2361,15 @@ class GameData(object):
     def look_for_engines(self, packages, force=False):
         engines = set(p.engine or self.engine for p in packages)
         engines.discard(None)
-        if len(engines) != 1:
-            # XXX: handle complex cases too (e.g. Inherit the Earth DE vs EN)
+        if not engines:
             return
 
+        # XXX: handle complex cases too (e.g. Inherit the Earth DE vs EN)
         status = FillResult.UNDETERMINED
-        for engine in reversed(list(engines)[0].split('|')):
-            engine = engine.strip()
-            status |= self.look_for_engine(engine)
+        for engine_alternative in engines:
+            for engine in reversed(engine_alternative.split('|')):
+                engine = engine.strip()
+                status |= self.look_for_engine(engine)
 
         if status is FillResult.IMPOSSIBLE:
             if force:

-- 
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