From 3fdeb9234a14f9168e5ee8df167d02235dc59e7d Mon Sep 17 00:00:00 2001 From: Oded Ben Ozer Date: Wed, 12 Jun 2024 09:47:10 +0200 Subject: [PATCH] Fix some merge bug --- go.mod | 12 +++++++----- go.sum | 6 ++++-- internal/pkg/githubapi/promotion.go | 2 +- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/go.mod b/go.mod index 2c5e8bba..6907ddd1 100644 --- a/go.mod +++ b/go.mod @@ -9,20 +9,24 @@ require ( github.com/argoproj/argo-cd/v2 v2.11.0-rc1 github.com/argoproj/gitops-engine v0.7.1-0.20240411122334-1ade3a199867 github.com/bradleyfalzon/ghinstallation/v2 v2.10.0 + github.com/cenkalti/backoff/v4 v4.2.1 github.com/go-test/deep v1.1.0 - github.com/google/go-github/v52 v52.0.0 + github.com/golang/mock v1.6.0 + github.com/google/go-cmp v0.6.0 + github.com/google/go-github/v62 v62.0.0 github.com/hashicorp/golang-lru/v2 v2.0.7 github.com/hexops/gotextdiff v1.0.3 github.com/migueleliasweb/go-github-mock v0.0.22 github.com/mikefarah/yq/v4 v4.43.1 github.com/prometheus/client_golang v1.19.0 - github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 github.com/shurcooL/githubv4 v0.0.0-20240120211514-18a1ae0e79dc github.com/sirupsen/logrus v1.9.3 github.com/spf13/cobra v1.8.0 golang.org/x/exp v0.0.0-20240409090435-93d18d7e34b8 golang.org/x/oauth2 v0.19.0 + google.golang.org/grpc v1.63.2 gopkg.in/yaml.v2 v2.4.0 + k8s.io/api v0.26.11 k8s.io/apimachinery v0.26.11 ) @@ -81,7 +85,6 @@ require ( github.com/google/btree v1.1.2 // indirect github.com/google/gnostic v0.7.0 // indirect github.com/google/gnostic-models v0.6.9-0.20230804172637-c7be7c783f49 // indirect - github.com/google/go-cmp v0.6.0 // indirect github.com/google/go-github/v56 v56.0.0 // indirect github.com/google/go-github/v60 v60.0.0 // indirect github.com/google/go-querystring v1.1.0 // indirect @@ -134,6 +137,7 @@ require ( github.com/redis/go-redis/v9 v9.5.1 // indirect github.com/robfig/cron/v3 v3.0.1 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect + github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 // indirect github.com/shurcooL/graphql v0.0.0-20230722043721-ed46e5a46466 // indirect github.com/skeema/knownhosts v1.2.2 // indirect github.com/spf13/pflag v1.0.5 // indirect @@ -161,13 +165,11 @@ require ( google.golang.org/genproto v0.0.0-20240401170217-c3f982113cda // indirect google.golang.org/genproto/googleapis/api v0.0.0-20240401170217-c3f982113cda // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20240401170217-c3f982113cda // indirect - google.golang.org/grpc v1.63.2 // indirect google.golang.org/protobuf v1.33.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/op/go-logging.v1 v1.0.0-20160211212156-b2cb9fa56473 // indirect gopkg.in/warnings.v0 v0.1.2 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/api v0.26.11 // indirect k8s.io/apiextensions-apiserver v0.26.10 // indirect k8s.io/apiserver v0.26.11 // indirect k8s.io/cli-runtime v0.26.11 // indirect diff --git a/go.sum b/go.sum index 85c0e88e..76f4baa5 100644 --- a/go.sum +++ b/go.sum @@ -677,6 +677,8 @@ github.com/bsm/gomega v1.27.10 h1:yeMWxP2pV2fG3FgAODIY8EiRE3dy0aeFYt4l7wh6yKA= github.com/bsm/gomega v1.27.10/go.mod h1:JyEr/xRbxbtgWNi8tIEVPUYZ5Dzef52k01W3YH0H+O0= github.com/buger/jsonparser v1.1.1/go.mod h1:6RYKKt7H4d4+iWqouImQ9R2FZql3VbhNgx27UK13J/0= github.com/bwesterb/go-ristretto v1.2.3/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0= +github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= +github.com/cenkalti/backoff/v4 v4.2.1/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/census-instrumentation/opencensus-proto v0.3.0/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/census-instrumentation/opencensus-proto v0.4.1/go.mod h1:4T9NM4+4Vw91VeyqjLS6ao50K5bOcLKN6Q42XnYaRYw= @@ -922,12 +924,12 @@ github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeN github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-github/v52 v52.0.0 h1:uyGWOY+jMQ8GVGSX8dkSwCzlehU3WfdxQ7GweO/JP7M= -github.com/google/go-github/v52 v52.0.0/go.mod h1:WJV6VEEUPuMo5pXqqa2ZCZEdbQqua4zAk2MZTIo+m+4= github.com/google/go-github/v56 v56.0.0 h1:TysL7dMa/r7wsQi44BjqlwaHvwlFlqkK8CtBWCX3gb4= github.com/google/go-github/v56 v56.0.0/go.mod h1:D8cdcX98YWJvi7TLo7zM4/h8ZTx6u6fwGEkCdisopo0= github.com/google/go-github/v60 v60.0.0 h1:oLG98PsLauFvvu4D/YPxq374jhSxFYdzQGNCyONLfn8= github.com/google/go-github/v60 v60.0.0/go.mod h1:ByhX2dP9XT9o/ll2yXAu2VD8l5eNVg8hD4Cr0S/LmQk= +github.com/google/go-github/v62 v62.0.0 h1:/6mGCaRywZz9MuHyw9gD1CwsbmBX8GWsbFkwMmHdhl4= +github.com/google/go-github/v62 v62.0.0/go.mod h1:EMxeUqGJq2xRu9DYBMwel/mr7kZrzUOfQmmpYrZn2a4= github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8= github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= diff --git a/internal/pkg/githubapi/promotion.go b/internal/pkg/githubapi/promotion.go index 2e020952..22558916 100644 --- a/internal/pkg/githubapi/promotion.go +++ b/internal/pkg/githubapi/promotion.go @@ -121,7 +121,7 @@ func generateListOfRelevantComponents(ghPrClientDetails GhPrClientDetails, confi prom.InstrumentGhCall(resp) if err != nil { ghPrClientDetails.PrLogger.Errorf("could not get file list from GH API: err=%s\nstatus code=%v", err, resp.Response.Status) - return promotions, err + return nil, err } prFiles = append(prFiles, perPagePrFiles...) if resp.NextPage == 0 {