Chore: use go 1.26.2 (#123379)

* golang 1.26

* bump all modules and docker file

* fix plugins test

---------

Co-authored-by: Matheus Macabu <macabu.matheus@gmail.com>
This commit is contained in:
Ryan McKinley 2026-04-23 17:40:14 +03:00 committed by GitHub
parent aa863b5f98
commit b8fd1b6c6b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
52 changed files with 52 additions and 56 deletions

View file

@ -1,6 +1,6 @@
module air
go 1.25.9
go 1.26.2
tool github.com/air-verse/air

View file

@ -1,6 +1,6 @@
module cog
go 1.25.9
go 1.26.2
tool github.com/grafana/cog/cmd/cli

View file

@ -1,6 +1,6 @@
module cue
go 1.25.9
go 1.26.2
tool cuelang.org/go/cmd/cue

View file

@ -1,6 +1,6 @@
module golangci-lint
go 1.25.9
go 1.26.2
tool github.com/golangci/golangci-lint/v2/cmd/golangci-lint

View file

@ -1,6 +1,6 @@
module jb
go 1.25.9
go 1.26.2
tool github.com/jsonnet-bundler/jsonnet-bundler/cmd/jb

View file

@ -1,6 +1,6 @@
module lefthook
go 1.25.9
go 1.26.2
tool github.com/evilmartians/lefthook

View file

@ -1,6 +1,6 @@
module swagger
go 1.25.9
go 1.26.2
tool github.com/go-swagger/go-swagger/cmd/swagger

View file

@ -15,7 +15,7 @@ ARG JS_SRC=js-builder
# By using FROM instructions we can delegate dependency updates to dependabot
FROM alpine:3.23.4 AS alpine-base
FROM ubuntu:24.04 AS ubuntu-base
FROM golang:1.25.9-alpine AS go-builder-base
FROM golang:1.26.2-alpine AS go-builder-base
FROM --platform=${JS_PLATFORM} node:24-alpine AS js-builder-base
# Javascript build stage
FROM --platform=${JS_PLATFORM} ${JS_IMAGE} AS js-builder

View file

@ -8,7 +8,7 @@ WIRE_TAGS = "oss"
include .citools/Variables.mk
GO = go
GO_VERSION = 1.25.9
GO_VERSION = 1.26.2
GO_HOST_OS := $(shell $(GO) env GOHOSTOS)
GO_HOST_ARCH := $(shell $(GO) env GOHOSTARCH)
GO_LINT_FILES ?= $(shell ./scripts/go-workspace/golangci-lint-includes.sh)

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/advisor
go 1.25.9
go 1.26.2
require (
github.com/Masterminds/semver/v3 v3.4.0

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/alerting/alertenrichment
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana/pkg/apimachinery v0.0.0-20260118065639-60cb766a97d6

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/alerting/historian
go 1.25.9
go 1.26.2
require (
github.com/go-kit/log v0.2.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/alerting/notifications
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/alerting/rules
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/annotation
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/collections
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/correlations
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/dashboard
go 1.25.9
go 1.26.2
require (
cuelang.org/go v0.11.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/dashvalidator
go 1.25.9
go 1.26.2
require (
github.com/grafana/authlib/types v0.0.0-20260414201248-d766c8627a66

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/example
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/folder
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/iam
go 1.25.9
go 1.26.2
// transitive dependencies that need replaced
// TODO: stop depending on grafana core(

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/live
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/logsdrilldown
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/playlist
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/plugins
go 1.25.9
go 1.26.2
replace github.com/grafana/grafana => ../..

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/preferences
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/provisioning
go 1.25.9
go 1.26.2
require (
github.com/bwmarrin/snowflake v0.3.0

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/quotas
go 1.25.9
go 1.26.2
// transitive dependencies that need replaced
// TODO: stop depending on grafana core(

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/scope
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana/pkg/apimachinery v0.0.0-20260118065639-60cb766a97d6

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/secret
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/apps/shorturl
go 1.25.9
go 1.26.2
require (
github.com/grafana/grafana-app-sdk v0.53.1

View file

@ -1,6 +1,6 @@
module high-card
go 1.25.9
go 1.26.2
require github.com/prometheus/client_golang v1.23.2

View file

@ -1,6 +1,6 @@
module utf8-support
go 1.25.9
go 1.26.2
require (
github.com/prometheus/client_golang v1.23.2

View file

@ -1,4 +1,4 @@
FROM golang:1.25.9
FROM golang:1.26.2
ADD main.go /go/src/webhook/main.go

2
go.mod
View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana
go 1.25.9
go 1.26.2
// Direct requirements -- every entry needs an owner
require (

View file

@ -1,4 +1,4 @@
go 1.25.9
go 1.26.2
// The `skip:golangci-lint` comment tag is used to exclude the package from the `golangci-lint` GitHub Action.
// The module at the root of the repo (`.`) is excluded because ./pkg/... is included manually in the `golangci-lint` configuration.

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/hack
go 1.25.9
go 1.26.2
require k8s.io/code-generator v0.35.0

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/aggregator
go 1.25.9
go 1.26.2
require (
github.com/emicklei/go-restful/v3 v3.13.0

View file

@ -423,11 +423,7 @@ func TestMakePluginResourceRequestContentTypeEmpty(t *testing.T) {
// Go 1.26's httptest.ResponseRecorder.Write returns http.ErrBodyNotAllowed
// for status codes that disallow a body (204, 304). The error is expected
// because HTTPResponseSender unconditionally calls Write on the response.
//require.ErrorContains(t, err, "request method or response status code does not allow body")
// Uncomment when we finally upgrade and delete the one below
//require.Zero(t, resp.Header().Get("Content-Type"))
require.NoError(t, err)
require.True(t, resp.Flushed, "response should be flushed after request is processed")
require.ErrorContains(t, err, "request method or response status code does not allow body")
require.Zero(t, resp.Header().Get("Content-Type"))
}

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/apimachinery
go 1.25.9
go 1.26.2
require (
github.com/go-jose/go-jose/v4 v4.1.4

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/apiserver
go 1.25.9
go 1.26.2
require (
github.com/google/go-cmp v0.7.0

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/build
go 1.25.9
go 1.26.2
replace (
// TODO: remove these - the build system should not depend on Grafana code.

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/build/wire
go 1.25.9
go 1.26.2
require (
github.com/google/go-cmp v0.7.0

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/codegen
go 1.25.9
go 1.26.2
require (
cuelang.org/go v0.11.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/infra/features
go 1.25.9
go 1.26.2
require (
github.com/cespare/xxhash/v2 v2.3.0

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/plugins/codegen
go 1.25.9
go 1.26.2
replace github.com/grafana/grafana/pkg/codegen => ../../codegen

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/plugins
go 1.25.9
go 1.26.2
require (
github.com/Machiel/slugify v1.0.1

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/semconv
go 1.25.9
go 1.26.2
require go.opentelemetry.io/otel v1.43.0

View file

@ -1,6 +1,6 @@
module github.com/grafana/grafana/pkg/storage/unified/resource/kv
go 1.25.9
go 1.26.2
require (
github.com/DATA-DOG/go-sqlmock v1.5.2

View file

@ -1,5 +1,5 @@
module github.com/grafana/grafana/scripts/go-workspace
go 1.25.9
go 1.26.2
require golang.org/x/mod v0.33.0

View file

@ -1,5 +1,5 @@
module github.com/grafana/grafana/scripts/modowners
go 1.25.9
go 1.26.2
require golang.org/x/mod v0.33.0