Skip to content

Commit 52a70ed

Browse files
authored
Go 1.24, linter update, and resolve linter/vet issues (#10620)
Co-authored-by: changelog-bot <changelog-bot>
1 parent e1d9b9e commit 52a70ed

File tree

30 files changed

+123
-91
lines changed

30 files changed

+123
-91
lines changed

.github/workflows/static-analysis.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ jobs:
4949
# `make analyze` runs the linter with similar arguments to what we use here.
5050
# If this action fails, try running `make analyze` locally.
5151
with:
52-
version: v1.57.2
52+
version: v1.64.5
5353
args: --verbose --modules-download-mode=readonly --allow-parallel-runners
5454
skip-cache: true
5555
skip-save-cache: true

.golangci.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,9 @@ issues:
6262
# Set to 0 to disable.
6363
max-same-issues: 0
6464

65+
# Make issues output unique by line.
66+
uniq-by-line: true
67+
6568
run:
6669
# Number of CPUs to use when running golangci-lint.
6770
# Default: the number of logical CPUs in the machine
@@ -93,8 +96,5 @@ output:
9396
# Print linter name in the end of issue text.
9497
print-linter-name: true
9598

96-
# Make issues output unique by line.
97-
uniq-by-line: true
98-
9999
# Sort results by: filepath, line and column.
100100
sort-results: true
+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
changelog:
2+
- type: DEPENDENCY_BUMP
3+
description: Bumped the go version to 1.24.0
4+
dependencyOwner: golang
5+
dependencyRepo: go
6+
dependencyTag: v1.24.0
7+
issueLink: https://github.com/solo-io/solo-projects/issues/7609
8+
resolvesIssue: false

ci/cloudbuild/publish-artifacts.yaml

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
steps:
22

3-
- name: 'gcr.io/$PROJECT_ID/prepare-go-workspace:0.11.1'
3+
- name: 'gcr.io/$PROJECT_ID/prepare-go-workspace:0.12.0'
44
id: 'prepare-workspace'
55
args:
66
- '--repo-name'
@@ -51,7 +51,7 @@ steps:
5151
- create
5252
- --use
5353

54-
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.11.1'
54+
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.12.0'
5555
id: 'build-certgen-arm64-binary'
5656
args:
5757
- 'certgen-docker'
@@ -60,7 +60,7 @@ steps:
6060
- 'GOARCH=arm64'
6161

6262
# Run make targets to push docker images to quay.io
63-
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.11.1'
63+
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.12.0'
6464
id: 'publish-docker'
6565
args:
6666
- 'publish-docker'
@@ -86,7 +86,7 @@ steps:
8686
waitFor:
8787
- 'publish-docker'
8888

89-
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.11.1'
89+
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.12.0'
9090
id: 'release-chart'
9191
dir: *dir
9292
args:
@@ -101,7 +101,7 @@ steps:
101101
- 'gcr-auth'
102102

103103
# Run make targets to build and push docker images to GCR
104-
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.11.1'
104+
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.12.0'
105105
id: 'publish-docker-extended-gcr'
106106
dir: *dir
107107
args:

ci/cloudbuild/run-tests.yaml

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
steps:
22

3-
- name: 'gcr.io/$PROJECT_ID/prepare-go-workspace:0.11.1'
3+
- name: 'gcr.io/$PROJECT_ID/prepare-go-workspace:0.12.0'
44
id: 'prepare-workspace'
55
args:
66
- '--repo-name'
@@ -23,7 +23,7 @@ steps:
2323
cd /go/pkg
2424
gsutil cat gs://$PROJECT_ID-cache/gloo/gloo-mod.tar.gz | tar -xzf - || echo "untar mod cache failed; continuing because we can download deps as we need them"
2525
26-
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.11.1'
26+
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.12.0'
2727
id: 'prepare-envoy'
2828
dir: *dir
2929
entrypoint: 'bash'
@@ -77,7 +77,7 @@ steps:
7777
waitFor:
7878
- 'prepare-gcr-zone'
7979

80-
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.11.1'
80+
- name: 'gcr.io/$PROJECT_ID/go-mod-make:0.12.0'
8181
id: 'prepare-test-tools'
8282
dir: *dir
8383
args:
@@ -88,7 +88,7 @@ steps:
8888
- 'prepare-gcr-zone'
8989
- 'prepare-test-credentials'
9090

91-
- name: 'gcr.io/$PROJECT_ID/e2e-go-mod-ginkgo:0.11.1'
91+
- name: 'gcr.io/$PROJECT_ID/e2e-go-mod-ginkgo:0.12.0'
9292
id: 'run-tests'
9393
dir: *dir
9494
entrypoint: 'make'
@@ -99,7 +99,7 @@ steps:
9999
secretEnv:
100100
- 'JWT_PRIVATE_KEY'
101101

102-
- name: 'gcr.io/$PROJECT_ID/e2e-go-mod-ginkgo:0.11.1'
102+
- name: 'gcr.io/$PROJECT_ID/e2e-go-mod-ginkgo:0.12.0'
103103
id: 'run-e2e-tests'
104104
dir: *dir
105105
entrypoint: 'make'
@@ -110,7 +110,7 @@ steps:
110110
secretEnv:
111111
- 'JWT_PRIVATE_KEY'
112112

113-
- name: 'gcr.io/$PROJECT_ID/e2e-go-mod-ginkgo:0.11.1'
113+
- name: 'gcr.io/$PROJECT_ID/e2e-go-mod-ginkgo:0.12.0'
114114
id: 'run-hashicorp-e2e-tests'
115115
dir: *dir
116116
entrypoint: 'make'

cloudbuild-cache.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
options:
22
env:
3-
- "_GO_VERSION=1.23.3"
3+
- "_GO_VERSION=1.24.0"
44

55
steps:
66
- name: gcr.io/cloud-builders/gsutil

docs/content/guides/dev/setting-up-dev-environment.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Developing on Gloo Gateway requires the following to be installed on your system
1212

1313
- [`Make`](https://www.gnu.org/software/make/)
1414
- [`Git`](https://git-scm.com/)
15-
- [`Go`](https://golang.org/) (`solo-io` projects are built using version `1.23.3`)
15+
- [`Go`](https://golang.org/) (`solo-io` projects are built using version `1.24.0`)
1616
- `Protoc` (`solo-io` projects are built using version `3.6.1`)
1717
- Standard development tools like `gcc`
1818

@@ -28,7 +28,7 @@ xcode-select --install
2828
# install version of go in go.mod
2929
############################################
3030
# - macOS:
31-
brew install go@1.23
31+
brew install go@1.24
3232
# - other operating systems:
3333
# follow directions at https://go.dev/doc/install
3434

go.mod

+11-8
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/solo-io/gloo
22

3-
go 1.23.6
3+
go 1.24.0
44

55
// Note for developers: upgrading go will also require upgrading go in the following files:
66
// ./cloudbuild-cache.yaml,
@@ -49,17 +49,17 @@ require (
4949
github.com/saiskee/gettercheck v0.0.0-20210820204958-38443d06ebe0
5050
github.com/sergi/go-diff v1.2.0
5151
github.com/solo-io/go-list-licenses v0.1.4
52-
github.com/solo-io/go-utils v0.27.4
53-
github.com/solo-io/k8s-utils v0.9.0
54-
github.com/solo-io/protoc-gen-ext v0.0.25
55-
github.com/solo-io/protoc-gen-openapi v0.2.5
56-
github.com/solo-io/skv2 v0.42.0
52+
github.com/solo-io/go-utils v0.28.4
53+
github.com/solo-io/k8s-utils v0.10.0
54+
github.com/solo-io/protoc-gen-ext v0.1.0
55+
github.com/solo-io/protoc-gen-openapi v0.3.0
56+
github.com/solo-io/skv2 v0.43.0
5757

5858
// Pinned to the `k8s-1.32-bump` tag of solo-apis on `gloo-main` branch
5959
// Ref: https://github.com/solo-io/gloo/pull/9463/files#r1594409655 && https://solo-io-corp.slack.com/archives/C03MFATU265/p1716913420716729?thread_ts=1716476992.938679&cid=C03MFATU265
6060
// as to why it is now based off `gloo-main` and not `gloo-repo-branch`
6161
github.com/solo-io/solo-apis v0.0.0-20250218202255-bad789c9de63
62-
github.com/solo-io/solo-kit v0.37.0
62+
github.com/solo-io/solo-kit v0.38.0
6363
github.com/spf13/afero v1.11.0
6464
github.com/spf13/cobra v1.8.1
6565
github.com/spf13/pflag v1.0.5
@@ -103,6 +103,7 @@ require (
103103
github.com/prometheus/client_model v0.6.1
104104
github.com/prometheus/common v0.62.0
105105
github.com/quasilyte/go-ruleguard/dsl v0.3.22
106+
github.com/solo-io/cue v0.4.7
106107
github.com/stoewer/go-strcase v1.3.0
107108
github.com/stretchr/testify v1.10.0
108109
golang.org/x/exp v0.0.0-20241215155358-4a5509556b9e
@@ -274,6 +275,7 @@ require (
274275
github.com/modern-go/reflect2 v1.0.2 // indirect
275276
github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect
276277
github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect
278+
github.com/mpvl/unique v0.0.0-20150818121801-cbe035fff7de // indirect
277279
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
278280
github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f // indirect
279281
github.com/oklog/run v1.0.0 // indirect
@@ -300,7 +302,7 @@ require (
300302
github.com/sagikazarmark/slog-shim v0.1.0 // indirect
301303
github.com/shopspring/decimal v1.4.0 // indirect
302304
github.com/sirupsen/logrus v1.9.3 // indirect
303-
github.com/solo-io/anyvendor v0.1.0 // indirect
305+
github.com/solo-io/anyvendor v0.2.0 // indirect
304306
github.com/sourcegraph/conc v0.3.0 // indirect
305307
github.com/spf13/cast v1.7.0 // indirect
306308
github.com/subosito/gotenv v1.6.0 // indirect
@@ -327,6 +329,7 @@ require (
327329
golang.org/x/term v0.28.0 // indirect
328330
golang.org/x/text v0.21.0 // indirect
329331
golang.org/x/time v0.9.0 // indirect
332+
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect
330333
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
331334
gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect
332335
gopkg.in/inf.v0 v0.9.1 // indirect

0 commit comments

Comments
 (0)