diff options
author | zeripath <art27@cantab.net> | 2020-01-10 00:14:14 +0000 |
---|---|---|
committer | Lunny Xiao <xiaolunwen@gmail.com> | 2020-01-10 08:14:14 +0800 |
commit | 17b844a3ecbe1dd74bbde750e6a0adea07d92caa (patch) | |
tree | fcb344d7a72a0eab3bf1028e6a4975bc42e528a0 /services | |
parent | 6c46a563607de96f11a4248d3656cb158eba80f7 (diff) | |
download | gitea-17b844a3ecbe1dd74bbde750e6a0adea07d92caa.tar.gz gitea-17b844a3ecbe1dd74bbde750e6a0adea07d92caa.zip |
Move Errored PRs out of StatusChecking (#9675)
* Set Errored PRs out of StatusChecking
* Ensure that api status is correctly set too
* Update models/pull.go
Co-Authored-By: John Olheiser <42128690+jolheiser@users.noreply.github.com>
Co-authored-by: John Olheiser <42128690+jolheiser@users.noreply.github.com>
Diffstat (limited to 'services')
-rw-r--r-- | services/pull/check.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/services/pull/check.go b/services/pull/check.go index 74185b6815..b1b9505823 100644 --- a/services/pull/check.go +++ b/services/pull/check.go @@ -194,10 +194,14 @@ func TestPullRequests(ctx context.Context) { if err != nil { log.Error("GetPullRequestByID[%s]: %v", prID, err) continue + } else if pr.Status != models.PullRequestStatusChecking { + continue } else if manuallyMerged(pr) { continue } else if err = TestPatch(pr); err != nil { log.Error("testPatch[%d]: %v", pr.ID, err) + pr.Status = models.PullRequestStatusError + pr.UpdateCols("status") continue } checkAndUpdateStatus(pr) |