Skip to content

Commit

Permalink
switch to lazy reporter
Browse files Browse the repository at this point in the history
  • Loading branch information
motatoes committed Dec 21, 2024
1 parent 6df110b commit 44c1aff
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 12 deletions.
1 change: 1 addition & 0 deletions backend/controllers/github.go
Original file line number Diff line number Diff line change
Expand Up @@ -419,6 +419,7 @@ func handlePullRequestEvent(gh utils.GithubClientProvider, payload *github.PullR
return fmt.Errorf("error processing event")
}
}

diggerCommand, err := orchestrator_scheduler.GetCommandFromJob(jobsForImpactedProjects[0])
if err != nil {
log.Printf("could not determine digger command from job: %v", jobsForImpactedProjects[0].Commands)
Expand Down
5 changes: 2 additions & 3 deletions backend/services/spec.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,9 +116,8 @@ func GetSpecFromJob(job models.DiggerJob) (*spec.Spec, error) {
CommentId: strconv.FormatInt(*batch.CommentId, 10),
Job: jobSpec,
Reporter: spec.ReporterSpec{
//ReportingStrategy: "comments_per_run",
ReportingStrategy: "always_same_comment",
ReporterType: "lazy",
ReportingStrategy: "comments_per_run",
ReporterType: "basic",
ReportCommentId: job.Batch.PlaceholderCommentIdForReport,
},
Lock: spec.LockSpec{
Expand Down
9 changes: 0 additions & 9 deletions libs/spec/providers.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,15 +133,6 @@ func (r ReporterProvider) GetReporter(title string, reporterSpec ReporterSpec, c
IsSupportMarkdown: true,
ReportStrategy: strategy,
}, nil
case "lazy":
strategy := getStrategy(reporterSpec.ReportingStrategy)
ciReporter := reporting.CiReporter{
CiService: ciService,
PrNumber: prNumber,
IsSupportMarkdown: true,
ReportStrategy: strategy,
}
return ciReporter, nil
default:
return reporting.NoopReporter{}, nil
}
Expand Down

0 comments on commit 44c1aff

Please sign in to comment.