From e02c5b1b5787210dfbf89681d94e7861b30aa139 Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Thu, 27 Jun 2024 11:32:30 +0200 Subject: [PATCH] fix(runner): only check for errors when a task is no longer running --- lua/lazy/manage/runner.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lua/lazy/manage/runner.lua b/lua/lazy/manage/runner.lua index 6a016098..74d62544 100644 --- a/lua/lazy/manage/runner.lua +++ b/lua/lazy/manage/runner.lua @@ -100,16 +100,16 @@ function Runner:_start() local is_running = s.task and s.task:is_running() local step = self._pipeline[s.step] + if is_running then + -- still running + active = active + 1 -- selene:allow(empty_if) - if s.task and s.task:has_errors() then + elseif s.task and s.task:has_errors() then -- don't continue tasks if there are errors elseif step and step.task == "wait" and not resume then -- waiting for sync waiting = waiting + 1 wait_step = s.step - elseif is_running then - -- still running - active = active + 1 else next[#next + 1] = name end