From ba8ec0ee9c985e5692d2f75233cc63c7e35e27f4 Mon Sep 17 00:00:00 2001 From: Kevin Jaget Date: Fri, 5 Feb 2021 17:08:00 -0500 Subject: [PATCH] In catkin build, preserve original job list topological ordering when (#626) moving jobs from pending to queued --- catkin_tools/execution/executor.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/catkin_tools/execution/executor.py b/catkin_tools/execution/executor.py index 83c5c744..bbceb3be 100644 --- a/catkin_tools/execution/executor.py +++ b/catkin_tools/execution/executor.py @@ -342,7 +342,10 @@ async def execute_jobs( new_queued_jobs, pending_jobs = split( pending_jobs, lambda j: j.all_deps_completed(completed_jobs)) - queued_jobs.extend(new_queued_jobs) + new_queued_jobs.extend(queued_jobs) + + # queued jobs should preserve the original topological sort of jobs + queued_jobs = [j for j in jobs if j in new_queued_jobs] # Notify of newly queued jobs for queued_job in new_queued_jobs: