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

Ping peer continuously closed channel #3053

Closed
KaloyanTanev opened this issue Apr 29, 2024 · 1 comment
Closed

Ping peer continuously closed channel #3053

KaloyanTanev opened this issue Apr 29, 2024 · 1 comment
Assignees
Labels
protocol Protocol Team tickets

Comments

@KaloyanTanev
Copy link
Contributor

KaloyanTanev commented Apr 29, 2024

🐞 Bug Report

On command alpha test peers sometimes during peer pinging there is panic because of a closed channel. This is caused because we close the channel testResCh in peerPingLoadTest function and try to send data on it afterwards in pingPeerContinuously.

🔬 Minimal Reproduction

Run ping peer tests with 2 or more peers. Not guaranteed to error every time as it is dependant on async calls.

🔥 Error

panic: send on closed channel

goroutine 303 [running]:
github.com/obolnetwork/charon/cmd.pingPeerContinuously({0x101da42a0, 0x140005c0dc0}, {0x101db5960, 0x140000ec300}, {{0x14000880090, 0x27}, {0x0, 0x0, 0x0}, 0x0, ...}, ...)
        github.com/obolnetwork/charon/cmd/testpeers.go:216 +0x6c
created by github.com/obolnetwork/charon/cmd.peerPingLoadTest in goroutine 194
        github.com/obolnetwork/charon/cmd/testpeers.go:545 +0x39c
@KaloyanTanev KaloyanTanev self-assigned this Apr 29, 2024
@github-actions github-actions bot added the protocol Protocol Team tickets label Apr 29, 2024
obol-bulldozer bot pushed a commit that referenced this issue Apr 30, 2024
Fix writing to closed channel error.

category: bug 
ticket: #3053
@KaloyanTanev
Copy link
Contributor Author

Fixed by #3054

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
protocol Protocol Team tickets
Projects
None yet
Development

No branches or pull requests

1 participant