Skip to content
This repository was archived by the owner on Jul 11, 2025. It is now read-only.

Catch unregister() keyerror #212

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

schew2381
Copy link

From the linked issue:

The latest release, 2.2.2, has a problem with the bootstrap socket being double unregistered.
This only happens occasionally. See the example logs below.

I think the most obvious issue here is that socket node_id=bootstrap-1 is unregistered twice in a row and the second time, it throws. Also, it is related to #177. We suspect #156 has some problem. The PR description does not provide any test about how it solves the 100% CPU usage. Should we revert that pr?

I added logic to catch the KeyError, but also to skip the other logic in the loop if if the socket is closed.
Added tests as well for the _poll() function

Fixes #180

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bootstrap socket double unregister problem
1 participant