Skip to content

Demonstration showing go-ethereum rpc client blocking indefinitely when calling Unsubscribe

Notifications You must be signed in to change notification settings

dimroc/geth-blocks-unsubscribe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go-Ethereum rpc.Client#Unsubscribe blocks indefinitely

when called simultaneously with geth node shutdown:

asciicast

Repro steps:

To help emulate the environment needed to reproduce the bug, repro.sh bootstraps, runs and kills geth and main.go.

  1. ./repro.sh
  2. ps aftwerwards and ensure the go executable (ending with blockingbuild) is still running. Note that it will not respond to a regular kill command.
  3. Install dlv (go get -u github.com/derekparker/delve/cmd/dlv)
  4. Use dlv attach <pid> <binarypath> to attach to process
  5. List goroutines with goroutines
  6. Switch to goroutine stuck on go-ethereum send, i.e. goroutine 1
  7. Look at call stack with stack

This issue is indeed spurious, so step 2 won't always reproduce, but in practice it reproduced 75% of the time.

About

Demonstration showing go-ethereum rpc client blocking indefinitely when calling Unsubscribe

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published