From ad40ca5dfe91646eef044243d1c8b006c88a498e Mon Sep 17 00:00:00 2001 From: Nedyalko Dyakov Date: Thu, 19 Feb 2026 16:44:55 +0200 Subject: [PATCH 1/5] chore(go): update go version to 1.24 --- example/cluster-mget/go.mod | 2 +- example/del-keys-without-ttl/go.mod | 2 +- example/digest-optimistic-locking/go.mod | 2 +- example/disable-maintnotifications/go.mod | 2 +- example/hll/go.mod | 2 +- example/hset-struct/go.mod | 2 +- example/lua-scripting/go.mod | 2 +- example/maintnotifiations-pubsub/go.mod | 2 +- example/otel/go.mod | 2 +- example/redis-bloom/go.mod | 2 +- example/scan-struct/go.mod | 2 +- example/tls-cert-auth/go.mod | 2 +- example/tls-connection/go.mod | 2 +- extra/rediscensus/go.mod | 2 +- extra/rediscmd/go.mod | 2 +- extra/redisotel/go.mod | 2 +- extra/redisprometheus/go.mod | 2 +- go.mod | 2 +- internal/customvet/go.mod | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/example/cluster-mget/go.mod b/example/cluster-mget/go.mod index bf9a195a3d..900cea4cef 100644 --- a/example/cluster-mget/go.mod +++ b/example/cluster-mget/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/cluster-mget -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/del-keys-without-ttl/go.mod b/example/del-keys-without-ttl/go.mod index cc31360a40..e14f1f6c9c 100644 --- a/example/del-keys-without-ttl/go.mod +++ b/example/del-keys-without-ttl/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/del-keys-without-ttl -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/digest-optimistic-locking/go.mod b/example/digest-optimistic-locking/go.mod index d69316c4bb..fb50dda1a1 100644 --- a/example/digest-optimistic-locking/go.mod +++ b/example/digest-optimistic-locking/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/digest-optimistic-locking -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/disable-maintnotifications/go.mod b/example/disable-maintnotifications/go.mod index 5c68b726e4..ab920a180b 100644 --- a/example/disable-maintnotifications/go.mod +++ b/example/disable-maintnotifications/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/disable-maintnotifications -go 1.23 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/hll/go.mod b/example/hll/go.mod index 829788bd5b..5804ed1267 100644 --- a/example/hll/go.mod +++ b/example/hll/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/hll -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/hset-struct/go.mod b/example/hset-struct/go.mod index 6dd9bea449..f5904136eb 100644 --- a/example/hset-struct/go.mod +++ b/example/hset-struct/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/scan-struct -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/lua-scripting/go.mod b/example/lua-scripting/go.mod index f7847c2c43..0418bcf515 100644 --- a/example/lua-scripting/go.mod +++ b/example/lua-scripting/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/lua-scripting -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/maintnotifiations-pubsub/go.mod b/example/maintnotifiations-pubsub/go.mod index d402dc0c98..3ed6ec32db 100644 --- a/example/maintnotifiations-pubsub/go.mod +++ b/example/maintnotifiations-pubsub/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/pubsub -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/otel/go.mod b/example/otel/go.mod index 902c6c3577..7d002b96b2 100644 --- a/example/otel/go.mod +++ b/example/otel/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/otel -go 1.23.0 +go 1.24 toolchain go1.24.1 diff --git a/example/redis-bloom/go.mod b/example/redis-bloom/go.mod index c672fe5a02..d051f7a994 100644 --- a/example/redis-bloom/go.mod +++ b/example/redis-bloom/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/redis-bloom -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/scan-struct/go.mod b/example/scan-struct/go.mod index 6dd9bea449..f5904136eb 100644 --- a/example/scan-struct/go.mod +++ b/example/scan-struct/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/scan-struct -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/tls-cert-auth/go.mod b/example/tls-cert-auth/go.mod index 72cb1ae968..32940f6613 100644 --- a/example/tls-cert-auth/go.mod +++ b/example/tls-cert-auth/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/tls-cert-auth -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/example/tls-connection/go.mod b/example/tls-connection/go.mod index 82ef7621c9..21e3f5b9a0 100644 --- a/example/tls-connection/go.mod +++ b/example/tls-connection/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/example/tls-connection -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/extra/rediscensus/go.mod b/extra/rediscensus/go.mod index 854636d6a8..e280683dc2 100644 --- a/extra/rediscensus/go.mod +++ b/extra/rediscensus/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/extra/rediscensus/v9 -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/extra/rediscmd/go.mod b/extra/rediscmd/go.mod index 68d7814d8f..70c84b7102 100644 --- a/extra/rediscmd/go.mod +++ b/extra/rediscmd/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/extra/rediscmd/v9 -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/extra/redisotel/go.mod b/extra/redisotel/go.mod index 9dbb1f27f0..529af07549 100644 --- a/extra/redisotel/go.mod +++ b/extra/redisotel/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/extra/redisotel/v9 -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/extra/redisprometheus/go.mod b/extra/redisprometheus/go.mod index d5564ac0cb..fd9fc80413 100644 --- a/extra/redisprometheus/go.mod +++ b/extra/redisprometheus/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/extra/redisprometheus/v9 -go 1.21 +go 1.24 replace github.com/redis/go-redis/v9 => ../.. diff --git a/go.mod b/go.mod index 613b2c4ae6..4b96706d03 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/v9 -go 1.21 +go 1.24 require ( github.com/bsm/ginkgo/v2 v2.12.0 diff --git a/internal/customvet/go.mod b/internal/customvet/go.mod index 202fd404da..06578584e8 100644 --- a/internal/customvet/go.mod +++ b/internal/customvet/go.mod @@ -1,6 +1,6 @@ module github.com/redis/go-redis/internal/customvet -go 1.21 +go 1.24 require golang.org/x/tools v0.5.0 From ec952d71d5505117b7aeda3b90113251075ff402 Mon Sep 17 00:00:00 2001 From: Nedyalko Dyakov Date: Thu, 19 Feb 2026 16:53:14 +0200 Subject: [PATCH 2/5] update readmes and ci workflows --- .github/actions/run-tests/action.yml | 4 ++-- .github/workflows/build.yml | 6 ++---- .github/workflows/test-e2e.yml | 1 - README.md | 5 ++--- example/otel-metrics/README.md | 2 +- 5 files changed, 7 insertions(+), 11 deletions(-) diff --git a/.github/actions/run-tests/action.yml b/.github/actions/run-tests/action.yml index 2093568f09..14e98223e8 100644 --- a/.github/actions/run-tests/action.yml +++ b/.github/actions/run-tests/action.yml @@ -3,7 +3,7 @@ description: 'Runs go-redis tests against different Redis versions and configura inputs: go-version: description: 'Go version to use for running tests' - default: '1.23' + default: '1.24' redis-version: description: 'Redis version to test against' required: true @@ -11,7 +11,7 @@ runs: using: "composite" steps: - name: Set up ${{ inputs.go-version }} - uses: actions/setup-go@v5 + uses: actions/setup-go@v6 with: go-version: ${{ inputs.go-version }} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b61f0fecbd..a6867d5355 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,8 +23,7 @@ jobs: - "8.2.x" # Redis CE 8.2 - "8.0.x" # Redis CE 8.0 go-version: - - "1.21.x" - - "1.23.x" + - "1.24.x" - oldstable - stable @@ -83,8 +82,7 @@ jobs: - "8.2.x" # Redis CE 8.2 - "8.0.x" # Redis CE 8.0 go-version: - - "1.21.x" - - "1.23.x" + - "1.24.x" - oldstable - stable diff --git a/.github/workflows/test-e2e.yml b/.github/workflows/test-e2e.yml index c544626de1..a2db30f1e5 100644 --- a/.github/workflows/test-e2e.yml +++ b/.github/workflows/test-e2e.yml @@ -17,7 +17,6 @@ jobs: fail-fast: false matrix: go-version: - - "1.23.x" - stable steps: diff --git a/README.md b/README.md index 160714ab09..8e7fd22ad5 100644 --- a/README.md +++ b/README.md @@ -21,9 +21,8 @@ In `go-redis` we are aiming to support the last three releases of Redis. Current - [Redis 8.2](https://raw.githubusercontent.com/redis/redis/8.2/00-RELEASENOTES) - using Redis CE 8.2 - [Redis 8.4](https://raw.githubusercontent.com/redis/redis/8.4/00-RELEASENOTES) - using Redis CE 8.4 -Although the `go.mod` states it requires at minimum `go 1.21`, our CI is configured to run the tests against all three -versions of Redis and multiple versions of Go ([1.21](https://go.dev/doc/devel/release#go1.21.0), -[1.23](https://go.dev/doc/devel/release#go1.23.0), oldstable, and stable). We observe that some modules related test may not pass with +Although the `go.mod` states it requires at minimum `go 1.24`, our CI is configured to run the tests against all three +versions of Redis and multiple versions of Go ([1.24](https://go.dev/doc/devel/release#go1.24.0), oldstable, and stable). We observe that some modules related test may not pass with Redis Stack 7.2 and some commands are changed with Redis CE 8.0. Although it is not officially supported, `go-redis/v9` should be able to work with any Redis 7.0+. Please do refer to the documentation and the tests if you experience any issues. diff --git a/example/otel-metrics/README.md b/example/otel-metrics/README.md index 25ae8d7b2b..964b69bc96 100644 --- a/example/otel-metrics/README.md +++ b/example/otel-metrics/README.md @@ -14,7 +14,7 @@ This example demonstrates how to enable OpenTelemetry metrics for Redis operatio ## Prerequisites -- Go 1.23.0 or later +- Go 1.24.0 or later - Redis server running on `localhost:6379` - OTLP collector running on `localhost:4317` (optional) From 46d661e69b6baa456b01548fe1363d00712b5efe Mon Sep 17 00:00:00 2001 From: Nedyalko Dyakov Date: Thu, 19 Feb 2026 17:00:53 +0200 Subject: [PATCH 3/5] update dockerfile for proxy-fi-server --- Makefile | 6 +++--- maintnotifications/e2e/cmd/proxy-fi-server/Dockerfile | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 370f3880c5..bf4559eb66 100644 --- a/Makefile +++ b/Makefile @@ -49,7 +49,7 @@ test.ci: export RE_CLUSTER=$(RE_CLUSTER) && \ export RCE_DOCKER=$(RCE_DOCKER) && \ export REDIS_VERSION=$(REDIS_VERSION) && \ - go mod tidy -compat=1.18 && \ + go mod tidy && \ go vet && \ go test -v -coverprofile=coverage.txt -covermode=atomic ./... -race -skip Example); \ done @@ -63,7 +63,7 @@ test.ci.skip-vectorsets: export RE_CLUSTER=$(RE_CLUSTER) && \ export RCE_DOCKER=$(RCE_DOCKER) && \ export REDIS_VERSION=$(REDIS_VERSION) && \ - go mod tidy -compat=1.18 && \ + go mod tidy && \ go vet && \ go test -v -coverprofile=coverage.txt -covermode=atomic ./... -race \ -run '^(?!.*(?:VectorSet|vectorset|ExampleClient_vectorset)).*$$' -skip Example); \ @@ -118,5 +118,5 @@ go_mod_tidy: echo "go mod tidy in $${dir}"; \ (cd "$${dir}" && \ go get -u ./... && \ - go mod tidy -compat=1.18); \ + go mod tidy); \ done diff --git a/maintnotifications/e2e/cmd/proxy-fi-server/Dockerfile b/maintnotifications/e2e/cmd/proxy-fi-server/Dockerfile index 971a1f2864..711bd83812 100644 --- a/maintnotifications/e2e/cmd/proxy-fi-server/Dockerfile +++ b/maintnotifications/e2e/cmd/proxy-fi-server/Dockerfile @@ -1,5 +1,5 @@ # Build stage -FROM golang:1.21-alpine AS builder +FROM golang:1.24-alpine AS builder WORKDIR /build From 62b832ec160a88693a2586aa02b85a7e9e5f287f Mon Sep 17 00:00:00 2001 From: Nedyalko Dyakov Date: Thu, 19 Feb 2026 17:37:26 +0200 Subject: [PATCH 4/5] address changed test behaviour --- json_test.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/json_test.go b/json_test.go index f68625c2ce..170d734c5e 100644 --- a/json_test.go +++ b/json_test.go @@ -832,7 +832,8 @@ var _ = Describe("Go-Redis Advanced JSON and RediSearch Tests", func() { typeCmd := client.JSONType(ctx, "person:1", "$.person.nickname") nicknameType, err := typeCmd.Result() Expect(err).NotTo(HaveOccurred(), "JSON.TYPE failed") - Expect(nicknameType[0]).To(Equal([]interface{}{"string"}), "JSON.TYPE mismatch for nickname") + // RESP2 v RESP3 + Expect(nicknameType[0]).To(Or(Equal([]interface{}{"string"}), Equal("string")), "JSON.TYPE mismatch for nickname") createIndexCmd := client.Do(ctx, "FT.CREATE", "person_idx", "ON", "JSON", "PREFIX", "1", "person:", "SCHEMA", From 468c1b5640a81488c1147f2d6084967014989c23 Mon Sep 17 00:00:00 2001 From: Nedyalko Dyakov Date: Thu, 19 Feb 2026 17:43:59 +0200 Subject: [PATCH 5/5] address changed test behaviour --- json_test.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/json_test.go b/json_test.go index 170d734c5e..0d5285944c 100644 --- a/json_test.go +++ b/json_test.go @@ -832,6 +832,7 @@ var _ = Describe("Go-Redis Advanced JSON and RediSearch Tests", func() { typeCmd := client.JSONType(ctx, "person:1", "$.person.nickname") nicknameType, err := typeCmd.Result() Expect(err).NotTo(HaveOccurred(), "JSON.TYPE failed") + Expect(nicknameType).To(HaveLen(1), "JSON.TYPE should return one element") // RESP2 v RESP3 Expect(nicknameType[0]).To(Or(Equal([]interface{}{"string"}), Equal("string")), "JSON.TYPE mismatch for nickname") @@ -860,7 +861,10 @@ var _ = Describe("Go-Redis Advanced JSON and RediSearch Tests", func() { typeCmd = client.JSONType(ctx, "person:1", "$.settings.notifications.email") typeResult, err := typeCmd.Result() Expect(err).ToNot(HaveOccurred()) - Expect(typeResult[0]).To(BeEmpty(), "Expected JSON.TYPE to be empty for deleted field") + // After deletion, JSON.TYPE returns empty slice or slice with empty/nil value + if len(typeResult) > 0 { + Expect(typeResult[0]).To(Or(BeNil(), BeEmpty()), "Expected JSON.TYPE to be empty for deleted field") + } }) }) }