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

update go-multistream, stop using deprecated NegotiateLazy #1417

Merged
merged 2 commits into from
Apr 22, 2022

Conversation

marten-seemann
Copy link
Contributor

No description provided.

Copy link
Collaborator

@MarcoPolo MarcoPolo left a comment

Choose a reason for hiding this comment

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

Looks good. I didn't know NegotiateLazy was deprecated. Is that documented anywhere? It's not mentioned in this interface https://github.com/libp2p/go-libp2p-core/blob/master/protocol/switch.go#L62

@marten-seemann
Copy link
Contributor Author

Good point. We should deprecate it on the interface as well. PR incoming.

We just deprecated it in go-multistream yesterday, because it actually didn't do anything that deserved the name "lazy": multiformats/go-multistream#85.

Copy link
Contributor

@vyzo vyzo left a comment

Choose a reason for hiding this comment

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

CI is angry...

@marten-seemann
Copy link
Contributor Author

CI is angry...

oops, and angry in a very bad way (test timeouts). Debugging now. This should not have caused any failures...

@marten-seemann
Copy link
Contributor Author

The problem was occurring in the TestStreamsStress in mock/net. I've removed this test entirely.
This might be a bit yolo, but the problem with mock/net is that it tries to mock an entire networking stack. Specifically, streams are modeled as io.Pipes, which is not the best implementation of an actual stream, since reads and writes from an io.Pipe need to be synchronized.

Copy link
Contributor

@vyzo vyzo left a comment

Choose a reason for hiding this comment

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

LGTM

CI is still complaining for some checks reason however.

@marten-seemann marten-seemann merged commit 9aab068 into master Apr 22, 2022
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