mirror of
https://github.com/odoo/runbot.git
synced 2025-03-27 13:25:47 +07:00
[FIX] runbot: correct logging in method _ask_kill
This commit is contained in:
parent
54f3cb9488
commit
e265607b3f
@ -1275,14 +1275,14 @@ class runbot_build(osv.osv):
|
|||||||
build._local_cleanup()
|
build._local_cleanup()
|
||||||
|
|
||||||
def _ask_kill(self, cr, uid, ids, context=None):
|
def _ask_kill(self, cr, uid, ids, context=None):
|
||||||
user = self.pool['res.users'].browse(cr, uid, uid, context=context)
|
user = self.pool['res.users'].browse(cr, SUPERUSER_ID, uid, context=context)
|
||||||
for build in self.browse(cr, SUPERUSER_ID, ids, context=context):
|
for build in self.browse(cr, SUPERUSER_ID, ids, context=context):
|
||||||
if build.state == 'pending':
|
if build.state == 'pending':
|
||||||
build._skip()
|
build._skip()
|
||||||
build.log('_ask_kill', 'Skipping build %s, requested by user %s (%s)' % build.dest, user.name, uid)
|
build._log('_ask_kill', 'Skipping build %s, requested by %s (user #%s)' % (build.dest, user.name, uid))
|
||||||
elif build.state in ['testing', 'running']:
|
elif build.state in ['testing', 'running']:
|
||||||
build.write({'state': 'deathrow'})
|
build.write({'state': 'deathrow'})
|
||||||
build.log('_ask_kill', 'Killing build %s, requested by user %s (%s)' % build.dest, user.name, uid)
|
build._log('_ask_kill', 'Killing build %s, requested by %s (user #%s)' % (build.dest, user.name, uid))
|
||||||
|
|
||||||
def _reap(self, cr, uid, ids):
|
def _reap(self, cr, uid, ids):
|
||||||
while True:
|
while True:
|
||||||
|
Loading…
Reference in New Issue
Block a user