From 3f35c00ee5d7c840e3e2d115c45aa564dff66b0d Mon Sep 17 00:00:00 2001 From: Conor Nash Date: Sat, 10 Oct 2026 13:36:15 +0100 Subject: [PATCH] Close orchestrator before deleting task cleanup test root --- tests/task-execution-tests.lisp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/task-execution-tests.lisp b/tests/task-execution-tests.lisp index aed58825..c2f10564 100644 --- a/tests/task-execution-tests.lisp +++ b/tests/task-execution-tests.lisp @@ -587,6 +587,12 @@ (when (and execution (not (job-terminal-p execution))) (job-cancel execution :reason ':test-cleanup)) (ignore-errors (lisp-worker-pool-stop-all worker-pool)) + ;; Pool listeners publish the durable completion record after the + ;; execution turns terminal; joining the pools ends that write. + (unless (task-orchestrator-close orchestrator) + (error 'task-error + :message "Task job pools did not stop before test cleanup." + :tool-name "task.run")) (platform-delete-directory-tree *platform* root :validate t :if-does-not-exist ':ignore))) nil)