horizoncd/horizon

View on GitHub
pkg/cluster/tekton/tekton_run.go

Summary

Maintainability
A
1 hr
Test Coverage
F
55%

Showing 2 of 2 total issues

Method Tekton.StopPipelineRun has 6 return statements (exceeds 4 allowed).
Open

func (t *Tekton) StopPipelineRun(ctx context.Context, ciEventID string) (err error) {
const op = "tekton: stop pipelineRun"
defer wlog.Start(ctx, op).StopPrint()
 
pr, err := t.GetPipelineRunByID(ctx, ciEventID)
Severity: Major
Found in pkg/cluster/tekton/tekton_run.go - About 40 mins to fix

    Method Tekton.CreatePipelineRun has 6 return statements (exceeds 4 allowed).
    Open

    func (t *Tekton) CreatePipelineRun(ctx context.Context, pr *PipelineRun) (eventID string, err error) {
    const op = "tekton: create pipelineRun"
    defer wlog.Start(ctx, op).StopPrint()
     
    bodyBytes, err := json.Marshal(pr)
    Severity: Major
    Found in pkg/cluster/tekton/tekton_run.go - About 40 mins to fix
      Category
      Status