Mercurial > bitten > bitten-test
diff bitten/master.py @ 494:9c9bf7a69bf0
Apply patch by Emmanuel Blot to allow a single slave to connect to multiple masters. Closes #271.
author | cmlenz |
---|---|
date | Tue, 08 Jul 2008 15:17:16 +0000 |
parents | 56f0ad35c60a |
children | 2f3b7c17d3c3 |
line wrap: on
line diff
--- a/bitten/master.py +++ b/bitten/master.py @@ -198,8 +198,10 @@ stepname = elem.attr['step'] # make sure it's the right slave. - if build.status != Build.IN_PROGRESS or build.slave_info.get(Build.IP_ADDRESS) != req.remote_addr: - raise HTTPForbidden('Build %s has been invalidated for host %s.' % (build.id, req.remote_addr)) + if build.status != Build.IN_PROGRESS or \ + build.slave_info.get(Build.IP_ADDRESS) != req.remote_addr: + raise HTTPForbidden('Build %s has been invalidated for host %s.' + % (build.id, req.remote_addr)) step = BuildStep.fetch(self.env, build=build.id, name=stepname) if step: @@ -216,8 +218,9 @@ raise HTTPForbidden('No such build step') last_step = index == num - self.log.debug('Slave %s (build %d) completed step %d (%s) with status %s', - build.slave, build.id, index, stepname, elem.attr['status']) + self.log.debug('Slave %s (build %d) completed step %d (%s) with ' + 'status %s', build.slave, build.id, index, stepname, + elem.attr['status']) db = self.env.get_db_cnx()