-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Identify protocol is not working? #460
Comments
Actually, as it turned out, the issue is not with the Identify protocol, but with Identify transport. But I still can't figure out how to use Identify transport and protocol on both sides. |
What is actually happening here, lets name nodes as D (dialer) and L (listener)
This way we end up in mutually locked nodes. |
I've realized this issue before. It can be bypassed by not resolving the info future if you receive a stream for identify. In polkadot we've moved to making secio mandatory so that we are guaranteed to have a peer ID without any trouble. If you really don't want secio, I think that an alternative would be to write a transport that handles identify on the side, using a different code path than the other protocols. |
While, in general, its a good thing to make Looking at #443, maybe it makes sense to implement protocol 3 (public-keys only) directly in |
Yes! That's indeed what I'd be going for. |
I was trying to build working
kademlia
example by splitting it into separate dialer/listener parts, but it still doesn't work.As it turned out, the issue is lying in the following code:
The Future
id_out.info
never resolves, so no connection is passed upward.To illustrate this issue I've created the simplified example by modifying echo-dialer/echo-server to include Identify transport. Complete example is located here - https://github.com/emotiq/rust-libp2p-identify-issue
Will try to dig deeper into the library to find out what is going on inside the protocol..
The text was updated successfully, but these errors were encountered: