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

Echo example: yamux potentially broken #258

Closed
paralin opened this issue Dec 25, 2017 · 6 comments
Closed

Echo example: yamux potentially broken #258

paralin opened this issue Dec 25, 2017 · 6 comments

Comments

@paralin
Copy link
Contributor

paralin commented Dec 25, 2017

I'm seeing the same error as in #164 in my app -

B> through /ip4/172.17.0.2/tcp/8085 (got <peer.ID USHmgZ>): Multiple errors: close tcp4 172.17.0.9:59630->172.17.0.2:8085: use of closed network connection

Use of closed network connection - I think internally the ipv4 connection is closed, but then reused somewhere.

This issue started when I added the yamux transport, like in the Echo demo.

@Stebalien
Copy link
Member

Is something actually failing to work? You can get that error if you, e.g., try to write/read (or, in some cases, close) a connection after or while closing a connection (which can happen under perfectly normal conditions).

(although, if we're printing that out as an error, we may want to consider reducing the log level).

@paralin
Copy link
Contributor Author

paralin commented Dec 26, 2017

This is an internal issue in libp2p, not me writing on a closed connection - I have the same issue with the echo demo, like in #164. Every time you run the dialer it prints this error.

@paralin
Copy link
Contributor Author

paralin commented Dec 27, 2017

I can't reproduce it anymore, a few days later. I think there is still some kind of internal bug in the yamux integration that may cause this though. Might be worth looking into it. I'll post again if I see it happen.

@Stebalien
Copy link
Member

Every time you run the dialer it prints this error.

But did it still connect (we conservatively double close connections all over the place)? Actually, that error looks truncated (at the beginning). Is there more?

@Stebalien
Copy link
Member

Stebalien commented Dec 27, 2017

Assuming the missing part of that error is misdial to <peer.ID $Something> where $Something != USHmgZ, you were probably not passing the correct peer ID on the client side. The full error is:

misdial to <some peer> through <some address> (got <other peer>): <additional errors>

@paralin
Copy link
Contributor Author

paralin commented Dec 28, 2017

You might be right. I haven't seen it again since, but I've been careful to copy/paste the peer ID each time. I'll close this for now, thanks for the help.

@paralin paralin closed this as completed Dec 28, 2017
marten-seemann pushed a commit that referenced this issue Apr 21, 2022
run connection gating tests on both TCP and QUIC
@MarcoPolo MarcoPolo mentioned this issue Jul 7, 2022
41 tasks
marten-seemann pushed a commit that referenced this issue Aug 17, 2022
* Add canonical logging for misbehaving peers

* Add component and use manet.FromNetAddr

* Fix log test
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

No branches or pull requests

2 participants