diff --git a/internal/services/gateway/api/run.go b/internal/services/gateway/api/run.go index f54f291..0bcb874 100644 --- a/internal/services/gateway/api/run.go +++ b/internal/services/gateway/api/run.go @@ -111,6 +111,11 @@ func createRunTaskResponse(rt *rstypes.RunTask, rct *rstypes.RunConfigTask) *gwa } rcts := rct.Steps[i] rts := rt.Steps[i] + + if rts.LogPhase == rstypes.RunTaskFetchPhaseFinished { + s.LogArchived = true + } + switch rcts := rcts.(type) { case *rstypes.RunStep: s.Type = "run" @@ -124,7 +129,6 @@ func createRunTaskResponse(rt *rstypes.RunTask, rct *rstypes.RunConfigTask) *gwa s.Shell = shell s.ExitStatus = rts.ExitStatus - case *rstypes.SaveToWorkspaceStep: s.Type = "save_to_workspace" s.Name = "save to workspace" diff --git a/services/gateway/api/types/run.go b/services/gateway/api/types/run.go index 0996f51..571c55d 100644 --- a/services/gateway/api/types/run.go +++ b/services/gateway/api/types/run.go @@ -106,6 +106,8 @@ type RunTaskResponseStep struct { StartTime *time.Time `json:"start_time"` EndTime *time.Time `json:"end_time"` + + LogArchived bool `json:"log_archived"` } type RunActionType string