diff options
author | Robert Speicher <robert@gitlab.com> | 2016-08-19 18:35:07 +0000 |
---|---|---|
committer | Robert Speicher <robert@gitlab.com> | 2016-08-19 18:35:07 +0000 |
commit | c711fe15dd2409161702f20a1ccffd861ae798ab (patch) | |
tree | 0d95446ad0e85c69fc04084cb7423a0d37b0620b /app/models/commit_status.rb | |
parent | 82a39e3e698b6332c44f036b735ae98926767057 (diff) | |
parent | a395b76286280d2b5e75ef25fca92dfffe691f71 (diff) | |
download | gitlab-ce-c711fe15dd2409161702f20a1ccffd861ae798ab.tar.gz |
Merge branch 'mark-as-processable' into 'master'
Make all future skipped builds as processable when retrying a build
## What does this MR do?
Makes a builds that are marked as skipped when a pipeline is processed to be reprocessed by changing their's state to created.
## Why was this MR needed?
Currently retry is broken. When you retry a build of pipeline it will succeed and be marked as succeeded, when the next stages should be triggered.
Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/21066
See merge request !5879
Diffstat (limited to 'app/models/commit_status.rb')
-rw-r--r-- | app/models/commit_status.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/commit_status.rb b/app/models/commit_status.rb index 7542399169f..84ceeac7d3e 100644 --- a/app/models/commit_status.rb +++ b/app/models/commit_status.rb @@ -31,6 +31,10 @@ class CommitStatus < ActiveRecord::Base transition [:created, :skipped] => :pending end + event :process do + transition skipped: :created + end + event :run do transition pending: :running end |