Add leanp2p transport interop tests#31
Conversation
|
🧐 I'm not concerned about the zig-v0.0.1 failures. I think we're likely to add that to the However, I am concerned about the rust-libp2p failures. Notice that it is only one way (i.e. leanp2p dialing rust and not the other way around). Let me run this locally with debug output enabled to see if we can deduce what's going on. |
|
I was able to recreate the failures locally and it looks like there's a ping protocol error happening when leanp2p dials rust-libp2p: |
Yes, I had already seen this happen when testing the integration with test-plans. I have reviewed the code thoroughly and my debug runs showed that the rust listener did not return back a ping value in the non-refactored code. Essentially it was failing at |
|
@bismuth01 hrm...that's interesting. I wonder where the bug lies. It's definitely an upstream bug, but whether it is in leanp2p or rust-libp2p remains to be seen. Do you know how to debug this? Do you need help debugging the rust-libp2p implementation? |
|
Let me try debugging it solo, I will ask for help if needed. |
|
any progress? |
|
Nope.
The best guess that I currently have is that Rust is closing the stream after host connection and the programs crash on negotiating an upgrade to quic. Also, the leanp2p x rust-v0.56 fails. But rust-v0.56 x leanp2p fails too as it faces a connection upgrade issue but rust still returns a successful run yaml, which can be checked in the test run logs in debug mode. I have tried debugging the rust-libp2p side, but they use a trace logger so I can't find exact function points where they give out a particular log. If possible, I would like some help on the rust side. tracing::debug!("{event:?}")Another thing I noticed is for leanp2p dialer, the output is not being parsed properly, that could be a result to due to the new macros placed in the script, but I will have to dig deeper. |
|
An update on the issue, after more digging and comparing logs from other tests and implementations, it seems that leanp2p tends to close stream earlier than expected when acting as listener. This comes up after the peer has connected and protocol negotiation fails as leanp2p closes stream. But what's more interesting is other tests report a success even though leanp2p listener fails protocol negotiations and never reaches ping protocol usage. I guess something can be done there. |
…ions The previous leanp2p transport failed to produce results due to abrupt stream closing and results couldn't be parsed due to logger based result output, both of which are fixed now.
|
The fix was implemented to the leanp2p transport script in this PR and tested with ./run.sh --impl-ignore "~failing" --transport-select "quic-v1"All 25 tests passed. Every single one with leanp2p listener passed and the ones with leanp2p dialer sucessfully outputted results that was parsed by the framework. |
The leanp2p transport scripts as well as the docker container have been merged in the official leanp2p repository and the image has been added to
transport/images.yml.