[ACTIONS] on.schedule: do not cancel jobs

The cancelation of jobs is taken care of by handleWorkflows which is
called right after handleSchedules with the same event.

(cherry picked from commit ad1af2e436)
(cherry picked from commit e21252f147)
(cherry picked from commit 08195803eb)
This commit is contained in:
Earl Warren 2023-12-23 12:18:51 +01:00
parent d10830e238
commit 9ddecee23a
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00

View file

@ -461,18 +461,6 @@ func handleSchedules(
Content: dwf.Content, Content: dwf.Content,
} }
// cancel running jobs if the event is push
if run.Event == webhook_module.HookEventPush {
// cancel running jobs of the same workflow
if err := actions_model.CancelRunningJobs(
ctx,
run.RepoID,
run.Ref,
run.WorkflowID,
); err != nil {
log.Error("CancelRunningJobs: %v", err)
}
}
crons = append(crons, run) crons = append(crons, run)
} }