Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

panic: interface conversion: interface {} is *gredis.Subscription, not *gredis.Message #3333

Open
StrangeYear opened this issue Feb 27, 2024 · 1 comment
Assignees
Labels
bug It is confirmed a bug, but don't worry, we'll handle it. need more details

Comments

@StrangeYear
Copy link

(

return v.Val().(*gredis.Message), nil
)

When subscribing to the Redis message queue for the first time, this line of code will return a panic.

2024-02-27 18:19:07.007 | panic: interface conversion: interface {} is *gredis.Subscription, not *gredis.Message |  
-- | -- | --
  |   | 2024-02-27 18:19:07.007 | /data/go/pkg/mod/github.com/gogf/gf/contrib/nosql/redis/[email protected]/redis_conn.go:248 +0xd1 |  
  |   | 2024-02-27 18:19:07.007 | github.com/gogf/gf/contrib/nosql/redis/v2.(*Conn).ReceiveMessage(0x3b9aca00?, {0x319ba40?, 0x498b000?}) |  
  |   | 2024-02-27 18:19:07.007 | goroutine 75 [running]:
@StrangeYear StrangeYear added the bug It is confirmed a bug, but don't worry, we'll handle it. label Feb 27, 2024
@gqcn gqcn self-assigned this Sep 13, 2024
@gqcn
Copy link
Member

gqcn commented Sep 13, 2024

@StrangeYear Hello, please provide minimum runnable codes that can reproduce this issue, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug It is confirmed a bug, but don't worry, we'll handle it. need more details
Projects
None yet
Development

No branches or pull requests

2 participants