Unlock task immediately if the locked_by PID isn't running

This commit is contained in:
tcely authored and GitHub committed 2025-02-07 06:26:24 -05:00
1 parent 104bac30ba
commit c48ec594c3
1 file changed
+2
+2
View File
@@ -828,6 +828,8 @@ class TasksView(ListView):
# Without this, the queue never resumes properly. # Without this, the queue never resumes properly.
if task.locked_by and not task.locked_by_pid_running(): if task.locked_by and not task.locked_by_pid_running():
task.locked_by = None task.locked_by = None
# do not wait for the task to expire
task.locked_at = None
task.save() task.save()
obj, url = map_task_to_instance(task) obj, url = map_task_to_instance(task)
if not obj: if not obj: