Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump google.golang.org/protobuf from 1.31.0 to 1.33.0 #148

Merged
merged 4 commits into from
Apr 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/linters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
run: |
go mod vendor
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
uses: golangci/golangci-lint-action@v4
with:
version: v1.53
version: latest
skip-cache: true
2 changes: 1 addition & 1 deletion cmd/topology/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func main() {
updateTracing(logger)

viper.WatchConfig()
viper.OnConfigChange(func(e fsnotify.Event) {
viper.OnConfigChange(func(_ fsnotify.Event) {
logger.WithField("file", defaultConfigFile).Info("configuration file changed")
updateDriverNames(volumeFinder)
updateLoggingSettings(logger)
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ require (
golang.org/x/text v0.13.0 // indirect
golang.org/x/time v0.3.0 // indirect
google.golang.org/appengine v1.6.8 // indirect
google.golang.org/protobuf v1.31.0 // indirect
google.golang.org/protobuf v1.33.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/ini.v1 v1.67.0 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -575,8 +575,8 @@ google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGj
google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c=
google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw=
google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc=
google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8=
google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I=
google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI=
google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
Expand Down
10 changes: 5 additions & 5 deletions internal/k8s/k8sapi_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,19 @@ func Test_GetPersistentVolumes(t *testing.T) {
type configFn func() (*rest.Config, error)
check := func(fns ...checkFn) []checkFn { return fns }

hasNoError := func(t *testing.T, volumes *corev1.PersistentVolumeList, err error) {
hasNoError := func(t *testing.T, _ *corev1.PersistentVolumeList, err error) {
if err != nil {
t.Fatalf("expected no error")
}
}

checkExpectedOutput := func(expectedOutput *corev1.PersistentVolumeList) func(t *testing.T, volumes *corev1.PersistentVolumeList, err error) {
return func(t *testing.T, volumes *corev1.PersistentVolumeList, err error) {
return func(t *testing.T, volumes *corev1.PersistentVolumeList, _ error) {
assert.Equal(t, expectedOutput, volumes)
}
}

hasError := func(t *testing.T, volumes *corev1.PersistentVolumeList, err error) {
hasError := func(t *testing.T, _ *corev1.PersistentVolumeList, err error) {
if err == nil {
t.Fatalf("expected error")
}
Expand All @@ -74,7 +74,7 @@ func Test_GetPersistentVolumes(t *testing.T) {
return connect, nil, check(hasNoError, checkExpectedOutput(volumes))
},
"error connecting": func(*testing.T) (connectFn, configFn, []checkFn) {
connect := func(api *k8s.API) error {
connect := func(_ *k8s.API) error {
return errors.New("error")
}
return connect, nil, check(hasError)
Expand Down Expand Up @@ -127,7 +127,7 @@ func Test_NewForConfigError(t *testing.T) {
oldNewConfigFn := k8s.NewConfigFn
defer func() { k8s.NewConfigFn = oldNewConfigFn }()
expected := "could not create Clientset from KubeConfig"
k8s.NewConfigFn = func(config *rest.Config) (*kubernetes.Clientset, error) {
k8s.NewConfigFn = func(_ *rest.Config) (*kubernetes.Clientset, error) {
return nil, fmt.Errorf(expected)
}

Expand Down
6 changes: 3 additions & 3 deletions internal/k8s/volume_finder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,19 +39,19 @@ func Test_K8sPersistentVolumeFinder(t *testing.T) {
type checkFn func(*testing.T, []k8s.VolumeInfo, error)
check := func(fns ...checkFn) []checkFn { return fns }

hasNoError := func(t *testing.T, volumes []k8s.VolumeInfo, err error) {
hasNoError := func(t *testing.T, _ []k8s.VolumeInfo, err error) {
if err != nil {
t.Fatalf("expected no error")
}
}

checkExpectedOutput := func(expectedOutput []k8s.VolumeInfo) func(t *testing.T, volumes []k8s.VolumeInfo, err error) {
return func(t *testing.T, volumes []k8s.VolumeInfo, err error) {
return func(t *testing.T, volumes []k8s.VolumeInfo, _ error) {
assert.Equal(t, expectedOutput, volumes)
}
}

hasError := func(t *testing.T, volumes []k8s.VolumeInfo, err error) {
hasError := func(t *testing.T, _ []k8s.VolumeInfo, err error) {
if err == nil {
t.Fatalf("expected error")
}
Expand Down
18 changes: 9 additions & 9 deletions internal/service/service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ func TestSearchHandler(t *testing.T) {
check := func(fns ...checkFn) []checkFn { return fns }

hasExpectedStatusCode := func(expectedStatus int) func(t *testing.T, response *http.Response, err error) {
return func(t *testing.T, response *http.Response, err error) {
return func(t *testing.T, response *http.Response, _ error) {
assert.NotNil(t, response)
assert.Equal(t, expectedStatus, response.StatusCode)
}
Expand Down Expand Up @@ -189,7 +189,7 @@ func TestSearchHandler(t *testing.T) {
},
}
patch := testOverrides{
marshalFn: func(v interface{}) ([]byte, error) {
marshalFn: func(_ interface{}) ([]byte, error) {
return nil, errors.New("error")
},
}
Expand All @@ -211,7 +211,7 @@ func TestSearchHandler(t *testing.T) {
},
}
patch := testOverrides{
decodeBodyFn: func(body io.Reader, v interface{}) error {
decodeBodyFn: func(_ io.Reader, _ interface{}) error {
return errors.New("error")
},
}
Expand All @@ -235,7 +235,7 @@ func TestSearchHandler(t *testing.T) {
volumeFinder.EXPECT().GetPersistentVolumes(gomock.Any()).Times(1).Return(volumeInfo, nil)

patch := testOverrides{
httpWrite: func(w *http.ResponseWriter, data []byte) (int, error) {
httpWrite: func(_ *http.ResponseWriter, _ []byte) (int, error) {
return 0, errors.New("error")
},
}
Expand Down Expand Up @@ -280,7 +280,7 @@ func TestQueryHandler(t *testing.T) {
check := func(fns ...checkFn) []checkFn { return fns }

hasExpectedStatusCode := func(expectedStatus int) func(t *testing.T, body []byte, statusCode int, err error) {
return func(t *testing.T, body []byte, statusCode int, err error) {
return func(t *testing.T, _ []byte, statusCode int, _ error) {
assert.Equal(t, expectedStatus, statusCode)
}
}
Expand Down Expand Up @@ -391,7 +391,7 @@ func TestQueryHandler(t *testing.T) {
volumeFinder.EXPECT().GetPersistentVolumes(gomock.Any()).Times(1).Return(volumeInfo, nil)

patch := testOverrides{
marshalFn: func(v interface{}) ([]byte, error) {
marshalFn: func(_ interface{}) ([]byte, error) {
return nil, errors.New("error")
},
}
Expand All @@ -408,7 +408,7 @@ func TestQueryHandler(t *testing.T) {
},
}
patch := testOverrides{
decodeBodyFn: func(body io.Reader, v interface{}) error {
decodeBodyFn: func(_ io.Reader, _ interface{}) error {
return errors.New("error")
},
}
Expand All @@ -426,7 +426,7 @@ func TestQueryHandler(t *testing.T) {
},
}
patch := testOverrides{
unMarshalFn: func(_ []byte, v interface{}) error {
unMarshalFn: func(_ []byte, _ interface{}) error {
return errors.New("error")
},
}
Expand All @@ -445,7 +445,7 @@ func TestQueryHandler(t *testing.T) {
},
}
patch := testOverrides{
httpWrite: func(w *http.ResponseWriter, data []byte) (int, error) {
httpWrite: func(_ *http.ResponseWriter, _ []byte) (int, error) {
return 0, errors.New("error")
},
}
Expand Down
Loading