From 7332277ca1edbc1473f2b376322b08b2177121f6 Mon Sep 17 00:00:00 2001 From: qingliu Date: Wed, 8 Apr 2026 00:32:19 -0500 Subject: [PATCH 1/2] chore: bump Go toolchain to 1.26.2 - Update repo Go version markers to 1.26.2 - Align kubectl staging module settings with the new toolchain --- .go-version | 2 +- go.mod | 2 +- go.work | 2 +- staging/src/k8s.io/kubectl/go.mod | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.go-version b/.go-version index dd43a143f0217..c7c3f3333e15d 100644 --- a/.go-version +++ b/.go-version @@ -1 +1 @@ -1.26.1 +1.26.2 diff --git a/go.mod b/go.mod index c8caf595e8525..69751d968e0d0 100644 --- a/go.mod +++ b/go.mod @@ -6,7 +6,7 @@ module k8s.io/kubernetes -go 1.26.1 +go 1.26.2 godebug default=go1.26 diff --git a/go.work b/go.work index 531ce61d89234..1285029279c3d 100644 --- a/go.work +++ b/go.work @@ -1,6 +1,6 @@ // This is a generated file. Do not edit directly. -go 1.26.1 +go 1.26.2 godebug default=go1.26 diff --git a/staging/src/k8s.io/kubectl/go.mod b/staging/src/k8s.io/kubectl/go.mod index df2f6f22dc15a..50617ff6201a0 100644 --- a/staging/src/k8s.io/kubectl/go.mod +++ b/staging/src/k8s.io/kubectl/go.mod @@ -2,9 +2,9 @@ module k8s.io/kubectl -go 1.25.7 +go 1.26.2 -godebug default=go1.25 +godebug default=go1.26 require ( github.com/MakeNowJust/heredoc v1.0.0 From 6923bd87a34381b4c547706f3f5cf12a2282256c Mon Sep 17 00:00:00 2001 From: qingliu Date: Wed, 8 Apr 2026 00:43:25 -0500 Subject: [PATCH 2/2] fix(test): fix wrong format arg type in describe_test.go Use key (string) instead of val (int) as the %q format argument in Errorf to fix the build failure: format %q has arg of wrong type int. Co-Authored-By: Claude Sonnet 4.6 --- staging/src/k8s.io/kubectl/pkg/describe/describe_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/staging/src/k8s.io/kubectl/pkg/describe/describe_test.go b/staging/src/k8s.io/kubectl/pkg/describe/describe_test.go index 8003354f52cf4..0b5561062501f 100644 --- a/staging/src/k8s.io/kubectl/pkg/describe/describe_test.go +++ b/staging/src/k8s.io/kubectl/pkg/describe/describe_test.go @@ -1228,10 +1228,10 @@ func TestDescribeResources(t *testing.T) { describeResources(testCase.resources, writer, LEVEL_1) output := out.String() gotElements := make(map[string]int) - for key, val := range testCase.expectedElements { + for key := range testCase.expectedElements { count := strings.Count(output, key) if count == 0 { - t.Errorf("expected to find %q in output: %q", val, output) + t.Errorf("expected to find %q in output: %q", key, output) continue } gotElements[key] = count