diff --git a/server.py b/server.py index c87d3f0..a2e30cc 100644 --- a/server.py +++ b/server.py @@ -1033,10 +1033,10 @@ def _run_kanban_agent(task_id: str): # Runs in a daemon thread: any unhandled exception would be lost and leave # the task stuck in "in_progress" forever, so catch failures and surface # them by marking the task blocked with the error. - path = kanban_task_path(task_id) - if not path.exists(): - return try: + path = kanban_task_path(task_id) + if not path.exists(): + return task = json.loads(path.read_text()) agent = task.get("assignee") prompt = task["title"] if not task.get("body") else f"{task['title']}\n\n{task['body']}"