Skip to content

Conversation

timwu20
Copy link
Contributor

@timwu20 timwu20 commented Oct 7, 2025

Changes

  • updates the str0m dependency to the commit which contains fixes I co-authored (PR #1, #2)
    • fixes str0m integration based on breaking public API changes
    • currently the references the latest commit hash, will update again when a release is cut by @algesten
  • fixes the decoding of multistream messages to support messages without trailing linebreak
  • removes trailing linebreak when encoding multistream message used for WebRTC
  • contributes to webrtc: Test the connection stability of the webrtc substreams #420

…cation, modify multistream protocol message, modify opening based on str0m api changes
remaining = &tail[len..];
if remaining.len() == 0 {
// During negotiation the remote may not append a trailing newline.
break;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this observed with smoldot integration?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was observed when testing against the libp2p native WebRTC transport. During negotiation, the libp2p native WebRTC transport doesn't append an extra newline.

}

// For the `Message::Protocols` to be interpreted correctly, it must be followed by a newline.
header.push(b'\n');
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could reach out to https://github.com/smol-dot/smoldot to align on the spec, then we could remove/simplify these functions.

We have diverged a bit from the spec, I wonder if this may break things down the line. Would the next message be interpreted correctly?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have @freddyli7 working on utilizing smoldot as a client to test against the libp2p server, as well as the litep2p server. We plan on getting it into litep2p-perf to run the performance behaviour. If things are incorrect in smoldot, we will create PRs upstream to fix them.

@algesten
Copy link

algesten commented Oct 7, 2025

@timwu20 I released 0.11.1

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.

3 participants