-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Open
Description
errUnexecptedRead
referred on internal/pool/pool.go
is undefined
Expected Behavior
ability to compile on Windows
Current Behavior
Unable to compile, error:
# github.com/redis/go-redis/v9/internal/pool
..\..\vendor\github.com\redis\go-redis\v9\internal\pool\pool.go:809:47: undefined: errUnexpectedRead
Possible Solution
The usage of
go-redis/internal/pool/pool.go
Line 809 in 1e6ee06
if p.cfg.PushNotificationsEnabled && err == errUnexpectedRead { |
is from:
go-redis/internal/pool/conn_check.go
Line 13 in 1e6ee06
var errUnexpectedRead = errors.New("unexpected read from socket") |
But it has build tag, which don't have Windows
go-redis/internal/pool/conn_check.go
Line 1 in 1e6ee06
//go:build linux || darwin || dragonfly || freebsd || netbsd || openbsd || solaris || illumos |
Environment
OS: Windows 11
redis_version:8.2.2
sdk:
- redis: v9.16.0-beta.1.0.20251017142310-1e6ee0674016 (master)
- redisotel: v9.16.0-beta.1.0.20251017142310-1e6ee0674016 (master)
Possible Implementation
IMO we can move the errUnexpectedRead
from conn_check.go
to pool.go
, but I haven't checked the feasibility
Metadata
Metadata
Assignees
Labels
No labels