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

address race condition in DHT initialization #635

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

Conversation

Vectorrent
Copy link
Contributor

This PR is an attempt to address some kind of race condition that can occur during expert bootstrapping. I spent several hours trying to identify the source of the problem, only to fall-back to an easy solution - which doesn't actually address the underlying problem.

For some reason, calling dht.get_visible_maddrs(True) on the DHT node fixes the issue. So, that's what we do now - every time the DHT node is started.

Since using get_visible_maddrs apparently fixes the problem, we can assume that something this method does is important to expert initialization. Yet, the only thing this method does is use Multiaddr; and so, I can only assume that there must be some kind of failure in Multiaddr, somewhere else in the code.

This is far outside my area of expertise, and I spent a lot of time troubleshooting already - so this is the best solution I could figure out, for now.

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

Successfully merging this pull request may close these issues.

1 participant