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

Monomer sometimes hangs on shutdown #279

Open
joshklop opened this issue Oct 28, 2024 · 0 comments
Open

Monomer sometimes hangs on shutdown #279

joshklop opened this issue Oct 28, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@joshklop
Copy link
Collaborator

joshklop commented Oct 28, 2024

Reproduce:

  1. Start devnet
  2. Use the example web app to deposit ETH on L2
  3. Shutdown Monomer

After examining a core dump, it appears Monomer gets blocked in env.Close when waiting for all websocket subscriptions to finish.

env.Defer(subscribeWg.Wait)

Based on the CometBFT event bus implementation, it appears that stopping the event bus before waiting on subscriptions would fix the issue. That means swapping the order of this DeferErr call and the Defer linked above:

env.DeferErr("stop event bus", eventBus.Stop)

Unfortunately, I don't have time to confirm that my understanding of the problem and solution is accurate, but this should be a good start.

@joshklop joshklop added the bug Something isn't working label Oct 28, 2024
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