From c3bf329a3adbc26dd87d91845a158e2a0dbc84c4 Mon Sep 17 00:00:00 2001 From: liuzx Date: Thu, 15 Dec 2022 10:52:14 +0800 Subject: [PATCH] fix-3393 --- routers/api/v1/repo/cloudbrain.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/routers/api/v1/repo/cloudbrain.go b/routers/api/v1/repo/cloudbrain.go index c2c06dcff..2ab733e21 100755 --- a/routers/api/v1/repo/cloudbrain.go +++ b/routers/api/v1/repo/cloudbrain.go @@ -763,11 +763,13 @@ func CloudbrainGetLog(ctx *context.APIContext) { if (job.JobType == string(models.JobTypeTrain) || job.JobType == string(models.JobTypeInference)) && job.Type == models.TypeCloudBrainOne && job.Status == string(models.JobFailed) { if ctx.Data["existStr"] != nil { - content = content + ctx.Data["existStr"].(string) if baseLine == "" && order == "desc" && result["Lines"].(int) == 0 { result["Lines"] = 1 result["EndLine"] = 1 } + if ctx.Data["existStr"] != nil && result["Lines"].(int) < 60 { + content = content + ctx.Data["existStr"].(string) + } } } else { if ctx.Data["existStr"] != nil && result["Lines"].(int) < 50 {