From 226e9897398a7e1ea6a09b3059393076dd08b3e8 Mon Sep 17 00:00:00 2001 From: Markus Bucher Date: Mon, 11 Nov 2024 16:57:02 +0100 Subject: [PATCH] Fix exception name --- lib/foreman_tasks.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/foreman_tasks.rb b/lib/foreman_tasks.rb index c4cfb9e83..1ff2f455e 100644 --- a/lib/foreman_tasks.rb +++ b/lib/foreman_tasks.rb @@ -33,7 +33,7 @@ def self.trigger_task(async, action, *args, &block) finished.wait(timeout) task = ForemanTasks::Task::DynflowTask.where(:external_id => id).first if task.nil? || (!task.paused? && task.pending?) - raise TimeoutError, "The time waiting for task #{task.try(:id)} to finish exceeded the 'foreman_tasks_sync_task_timeout' (#{timeout}s)" + raise Timeout::Error, "The time waiting for task #{task.try(:id)} to finish exceeded the 'foreman_tasks_sync_task_timeout' (#{timeout}s)" end end task || ForemanTasks::Task::DynflowTask.where(:external_id => id).first!