Rev 61: Find failed builds on the important arches. in http://people.canonical.com/~robertc/baz2.0/plugins/builder/blocking

Robert Collins robertc at robertcollins.net
Fri Oct 23 07:55:27 BST 2009


At http://people.canonical.com/~robertc/baz2.0/plugins/builder/blocking

------------------------------------------------------------
revno: 61
revision-id: robertc at robertcollins.net-20091023065525-h8plfxcyngg1o1zq
parent: robertc at robertcollins.net-20091023062829-9z2nkzg00yqyd6qp
committer: Robert Collins <robertc at robertcollins.net>
branch nick: blocking
timestamp: Fri 2009-10-23 17:55:25 +1100
message:
  Find failed builds on the important arches.
=== modified file 'ppa.py'
--- a/ppa.py	2009-10-23 06:28:29 +0000
+++ b/ppa.py	2009-10-23 06:55:25 +0000
@@ -50,6 +50,7 @@
     owner = launchpad.people[owner_name]
     archive = owner.getPPAByName(name=archive_name)
     end_states = ['failedtobuild', 'fullybuilt']
+    important_arches = ['amd64', 'i386', 'lpia', 'armel']
     print "Waiting for", version, "of", package_name, "to build."
     while True:
         sourceRecords = [s for s in
@@ -75,7 +76,7 @@
             missing = []
             for build in buildSummaries['builds']:
                 arch = build['arch_tag']
-                if arch in ['amd64', 'i386', 'lpia', 'armel']:
+                if arch in important_arches:
                     missing.append(arch)
             if not missing:
                 break
@@ -90,7 +91,12 @@
         result = 2
     if buildSummaries['status'] != 'FULLYBUILT':
         if buildSummaries['status'] == 'NEEDSBUILD':
-            import pdb;pdb.set_trace()
+            # We're stopping early cause the important_arches are built.
+            builds = pkg.getBuilds()
+            for build in builds:
+                if build.arch_tag in important_arches:
+                    if build.buildstate == 'Failed to build':
+                        result = 2
         else:
             result = 2
     return result




More information about the bazaar-commits mailing list