Skip to content

Commit

Permalink
chore: print log when skipping github run (#7818) (#7819)
Browse files Browse the repository at this point in the history
Co-authored-by: Klesh Wong <zhenmian.huang@merico.dev>
  • Loading branch information
github-actions[bot] and klesh committed Aug 1, 2024
1 parent cb51897 commit ebddfe3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions backend/plugins/github/tasks/cicd_run_collector.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ var CollectRunsMeta = plugin.SubTaskMeta{

func CollectRuns(taskCtx plugin.SubTaskContext) errors.Error {
data := taskCtx.GetData().(*GithubTaskData)
log := taskCtx.GetLogger()
collector, err := helper.NewStatefulApiCollectorForFinalizableEntity(helper.FinalizableApiCollectorArgs{
RawDataSubTaskArgs: helper.RawDataSubTaskArgs{
Ctx: taskCtx,
Expand Down Expand Up @@ -100,6 +101,8 @@ func CollectRuns(taskCtx plugin.SubTaskContext) errors.Error {
return nil, errors.Convert(err)
}
filteredRuns = append(filteredRuns, json.RawMessage(runJSON))
} else {
log.Info("Skipping run{id: %d, number: %d} with status %s", run.ID, run.RunNumber, run.Status)
}
}
return filteredRuns, nil
Expand Down

0 comments on commit ebddfe3

Please sign in to comment.