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

Client ping panics on direct call #1203

Open
icecube092 opened this issue Sep 29, 2023 · 0 comments
Open

Client ping panics on direct call #1203

icecube092 opened this issue Sep 29, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@icecube092
Copy link

What version of gotd are you using?

github.com/gotd/td v0.88.0

Can this issue be reproduced with the latest version?

yes

What did you do?

ping client directly by client.Ping with context timeout

What did you expect to see?

context deadline exceeded

What did you see instead?

panic:

/usr/local/go/src/runtime/panic.go:884\nruntime.panicmem\n\t
/usr/local/go/src/runtime/panic.go:260\nruntime.sigpanic\n\t
/usr/local/go/src/runtime/signal_unix.go:841\n
github.com/gotd/td/internal/mtproto.(*Conn).write\n\t
/go/pkg/mod/github.com/gotd/[email protected]/internal/mtproto/write.go:33\n
github.com/gotd/td/internal/mtproto.(*Conn).writeServiceMessage\n\t
/go/pkg/mod/github.com/gotd/[email protected]/internal/mtproto/write.go:15\n
github.com/gotd/td/internal/mtproto.(*Conn).Ping\n\t
/go/pkg/mod/github.com/gotd/[email protected]/internal/mtproto/ping.go:26\n
github.com/gotd/td/telegram/internal/manager.(*Conn).Ping\n\t
/go/pkg/mod/github.com/gotd/[email protected]/telegram/internal/manager/conn.go:250\n
github.com/gotd/td/telegram.(*Client).Ping\n\t
/go/pkg/mod/github.com/gotd/[email protected]/telegram/ping.go:9\n

What Go version and environment are you using?

go version go1.20.5 linux/amd64

Maybe panic occurs when client reconnected.

@icecube092 icecube092 added the bug Something isn't working label Sep 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant