From 465c3489225e0fac452140bd301e436b53ebc32e Mon Sep 17 00:00:00 2001 From: Jason Song Date: Fri, 4 Nov 2022 17:09:35 +0800 Subject: [PATCH] fix: show blocked jobs --- go.mod | 2 +- go.sum | 4 ++-- models/bots/run.go | 3 ++- web_src/js/components/RepoBuildView.vue | 1 + 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/go.mod b/go.mod index ee111c32ad..c548bae8f5 100644 --- a/go.mod +++ b/go.mod @@ -320,4 +320,4 @@ exclude github.com/gofrs/uuid v4.0.0+incompatible exclude github.com/goccy/go-json v0.4.11 -replace github.com/nektos/act => gitea.com/gitea/act v0.0.0-20221012054755-c2c76e19a725 +replace github.com/nektos/act => gitea.com/gitea/act v0.0.0-20221104080934-57978c14b59d diff --git a/go.sum b/go.sum index bba6b4231a..704b4dc4e5 100644 --- a/go.sum +++ b/go.sum @@ -81,8 +81,8 @@ contrib.go.opencensus.io/resource v0.1.1/go.mod h1:F361eGI91LCmW1I/Saf+rX0+OFcig dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= git.sr.ht/~mariusor/go-xsd-duration v0.0.0-20220703122237-02e73435a078 h1:cliQ4HHsCo6xi2oWZYKWW4bly/Ory9FuTpFPRxj/mAg= git.sr.ht/~mariusor/go-xsd-duration v0.0.0-20220703122237-02e73435a078/go.mod h1:g/V2Hjas6Z1UHUp4yIx6bATpNzJ7DYtD0FG3+xARWxs= -gitea.com/gitea/act v0.0.0-20221012054755-c2c76e19a725 h1:H5lZ5fqSXAZ082wBKfqaME070sw5DeNwT8Bwyfa5mcc= -gitea.com/gitea/act v0.0.0-20221012054755-c2c76e19a725/go.mod h1:lpzib6X73FHLSaTqTakan1xcsCAVhlZvPSpLns7jkRo= +gitea.com/gitea/act v0.0.0-20221104080934-57978c14b59d h1:Xfdo11dwHpcjFtH0qebucf6zUqei8z9eZ4f0IMvoLjw= +gitea.com/gitea/act v0.0.0-20221104080934-57978c14b59d/go.mod h1:lpzib6X73FHLSaTqTakan1xcsCAVhlZvPSpLns7jkRo= gitea.com/gitea/act_runner v0.0.0-20221015084035-e63e22e8c81d h1:WdZqNKX1TB0vH1nOFZhoYdesEGFwvwpKGkwjGaGCmgo= gitea.com/gitea/act_runner v0.0.0-20221015084035-e63e22e8c81d/go.mod h1:ZDTf3CZrtttQj0EzduNKPRUBPIrPOK6cdx/LFFVX+EE= gitea.com/gitea/proto-go v0.0.0-20221014123629-9116865c883b h1:TSz7VRHfnM/5JwGPgIAjSlDIvcr4pTGfuRMtgMxttmg= diff --git a/models/bots/run.go b/models/bots/run.go index c7755e83e3..103d03bd59 100644 --- a/models/bots/run.go +++ b/models/bots/run.go @@ -166,8 +166,9 @@ func InsertRun(run *Run, jobs []*jobparser.SingleWorkflow) error { runJobs := make([]*RunJob, 0, len(jobs)) for _, v := range jobs { id, job := v.Job() - payload, _ := v.Marshal() needs := job.Needs() + job.EraseNeeds() + payload, _ := v.Marshal() status := StatusWaiting if len(needs) > 0 { status = StatusBlocked diff --git a/web_src/js/components/RepoBuildView.vue b/web_src/js/components/RepoBuildView.vue index afe0cdf98b..de791887c3 100644 --- a/web_src/js/components/RepoBuildView.vue +++ b/web_src/js/components/RepoBuildView.vue @@ -40,6 +40,7 @@ +