Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.
Go
fix(server): cancel active tasks when issue status changes to cancelled (#940)
Bohan Jiang5e74c411dc74
diff --git a/server/internal/handler/issue.go b/server/internal/handler/issue.goindex 7a7049715c..2fcea202ec 100644--- a/server/internal/handler/issue.go+++ b/server/internal/handler/issue.go@@ -1122,6 +1122,13 @@ func (h *Handler) UpdateIssue(w http.ResponseWriter, r *http.Request) {}}+ // Cancel active tasks when the issue is cancelled by a user.+ // This is distinct from agent-managed status transitions — cancellation+ // is a user-initiated terminal action that should stop execution.+ if statusChanged && issue.Status == "cancelled" {+ h.TaskService.CancelTasksForIssue(r.Context(), issue.ID)+ }+writeJSON(w, http.StatusOK, resp)}@@ -1411,6 +1418,11 @@ func (h *Handler) BatchUpdateIssues(w http.ResponseWriter, r *http.Request) {}}+ // Cancel active tasks when the issue is cancelled by a user.+ if statusChanged && issue.Status == "cancelled" {+ h.TaskService.CancelTasksForIssue(r.Context(), issue.ID)+ }+updated++}