]> git.ipfire.org Git - people/jschlag/pbs.git/commitdiff
Fix creation of test builds.
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 12 Dec 2012 16:29:08 +0000 (17:29 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 12 Dec 2012 16:29:08 +0000 (17:29 +0100)
Test builds have not been created for all architectures.

backend/builds.py

index d204699306609e2ad348832eead09e8e57b0a4a5..ab5ce0310b451a32fb681225fd6cf4e239239156 100644 (file)
@@ -181,6 +181,7 @@ class Builds(base.Object):
                        WHERE NOT EXISTS \
                                (SELECT * FROM jobs WHERE \
                                        jobs.build_id = builds.id AND \
+                                       jobs.arch_id = %s AND \
                                        (jobs.state != 'finished' OR \
                                        jobs.time_finished >= %s) \
                                ) \
@@ -193,7 +194,7 @@ class Builds(base.Object):
                                        jobs.time_finished < %s \
                                ) \
                        AND builds.type = 'release' AND NOT builds.state = 'broken'"
-               args  = [threshold, arch.id, threshold]
+               args  = [arch.id, threshold, arch.id, threshold]
 
                if randomize:
                        query += " ORDER BY RAND()"