Skip to content

Commit d736cd4

Browse files
authored
go_sdk: upgrade to 1.26.0 (#11304)
Fix Redis URI IPv6 test generation for Go 1.26 > net/url > > Parse now rejects malformed URLs containing colons in the host subcomponent, such as http://::1/ or http://localhost:80:80/. > URLs containing bracketed IPv6 addresses, such as http://[::1]/ are still accepted. > The new GODEBUG setting urlstrictcolons=0 restores the old behavior. https://go.dev/doc/go1.26
1 parent fa0e2de commit d736cd4

File tree

3 files changed

+86
-85
lines changed

3 files changed

+86
-85
lines changed

MODULE.bazel.lock

Lines changed: 79 additions & 83 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

enterprise/server/util/redisutil/redisutil_test.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,14 @@ func genURI(scheme, user, password, addr, database string) string {
9696

9797
if strings.HasPrefix(scheme, "redis") {
9898
if host, port, err := net.SplitHostPort(addr); err == nil {
99-
hostport = host
10099
if port != "" {
101100
hostport = net.JoinHostPort(host, port)
101+
} else if strings.Contains(host, ":") {
102+
// Keep the trailing ":" so go-redis can default the port without
103+
// double-bracketing IPv6 hosts.
104+
hostport = net.JoinHostPort(host, port)
105+
} else {
106+
hostport = host
102107
}
103108
} else {
104109
return ""

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/buildbuddy-io/buildbuddy
22

3-
go 1.25.6
3+
go 1.26.0
44

55
// Device Manager
66
tool gitlab.com/arm-research/smarter/smarter-device-manager

0 commit comments

Comments
 (0)