diff --git a/runbot/models/runbot.py b/runbot/models/runbot.py index 737d0572..5f5ef876 100644 --- a/runbot/models/runbot.py +++ b/runbot/models/runbot.py @@ -136,7 +136,7 @@ class Runbot(models.AbstractModel): WHERE %s ORDER BY - array_position(array['normal','rebuild','indirect','scheduled']::varchar[], runbot_build.build_type) ASC + parent_path FOR UPDATE OF runbot_build SKIP LOCKED LIMIT %%s )