[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

extras-buildsys/client buildclient.py,1.14,1.15



Author: dcbw

Update of /cvs/fedora/extras-buildsys/client
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv10171/client

Modified Files:
	buildclient.py 
Log Message:
2005-06-24  Dan Williams <dcbw redhat com>

    * client/buildclient.py
        - Remove some debug strings
        - Fix undefined variable usage




Index: buildclient.py
===================================================================
RCS file: /cvs/fedora/extras-buildsys/client/buildclient.py,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- buildclient.py	24 Jun 2005 12:51:21 -0000	1.14
+++ buildclient.py	24 Jun 2005 17:11:21 -0000	1.15
@@ -65,6 +65,7 @@
         self._uniqid = uniqid
         self._status = 'init'
         self._repo_locked = True
+        self._repo_locked_msg = False
         self._files = []
         self._pobj = None
         self._target = target
@@ -217,7 +218,6 @@
                 break
         f.close()
         string = string.lower()
-        print "Mock state is '%s'" % string
         return string
 
     def process(self):
@@ -229,6 +229,11 @@
                 # server tells us the repo is unlocked.
                 if not self._repo_locked:
                     self._build()
+                else:
+                    # Only show this message once
+                    if not self._repo_locked_msg:
+                        self.log("Waiting for repository to unlock before starting the build...")
+                        self._repo_locked_msg = True
             elif self._status == 'prepping':
                 if not self._mock_is_prepping():
                     self._status = 'building'
@@ -255,7 +260,6 @@
                         else:
                             self.log("Error reading mock output: %s\n" % e)
                     else:
-                        print string
                         self._log_fd.write(string)
                         self._log_fd.flush()
                         os.fsync(self._log_fd.fileno())
@@ -266,11 +270,10 @@
                 if self._status == 'done':
                     self.log("Job completed successfully.\n")
                 elif self._status == 'failed':
+                    exit_status = self._pobj.poll()
                     self.log("Job failed due to mock errors!  mock exit status: %d\n" % exit_status)
                 elif self._status == 'killed':
                     self.log("Job failed because it was killed.\n")
-
-            print self._status
         else:
             if self._log_fd:
                 self._log_fd.close()


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]