[FIX] makes sure the build order is FIFO

instead of LIFO (for csn...)
This commit is contained in:
Gery Debongnie 2014-07-04 16:33:32 +02:00
parent 6d4324b251
commit a80d44b451

View File

@ -287,7 +287,7 @@ class runbot_repo(osv.osv):
# find sticky pending build if any, otherwise, last pending (by id, not by sequence) will do the job
pending_ids = bo.search(cr, uid, dom + [('state', '=', 'pending'), ('branch_id.sticky', '=', True)], limit=1)
if not pending_ids:
pending_ids = bo.search(cr, uid, dom + [('state', '=', 'pending')], order="id desc")
pending_ids = bo.search(cr, uid, dom + [('state', '=', 'pending')], order="sequence", limit=1)
pending = bo.browse(cr, uid, pending_ids[0])
pending.schedule()