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

From Discord: Potential Bug in @effect/platform-node/NodeStream.toReadable with Stream.concatAll #3542

Closed
effect-bot opened this issue Sep 3, 2024 · 0 comments · Fixed by #3543

Comments

@effect-bot
Copy link

Summary

Summary

  1. Issue Identification:

    • The user suspects a bug in @effect/platform-node/NodeStream.toReadable when used with Stream.concatAll.
    • The issue was discovered while using a stream as the body of an HTTP request with the undici layer, which utilizes NodeStream.toReadable.
  2. Minimal Reproducible Example (MRE):

    • The user provided a smaller minimal reproducible example (MRE) to demonstrate the issue.
  3. Potential Cause:

    • Another user, datner_, suggests that the problem might be with Stream.empty, which writes an empty chunk. This behavior could be causing issues with the Channel.
    • It is suggested that Stream.empty should use a void implementation similar to Stream.make.

Key Takeaways

  • Suspected Bug Location: @effect/platform-node/NodeStream.toReadable in combination with Stream.concatAll.
  • Context: The issue arises when using the stream as the body of an HTTP request with the undici layer.
  • Potential Root Cause: Stream.empty writing an empty chunk, which may trip up the Channel.
  • Suggested Fix: Modify Stream.empty to use a void implementation like Stream.make.

This summary encapsulates the main points and potential solutions discussed in the conversation.

Discord thread

https://discord.com/channels/795981131316985866/1280245858323140740

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 a pull request may close this issue.

1 participant