Open nounder opened 1 month ago
Here's workaround using Effect.all
:
import { Effect, Stream } from "effect"
const stream = Stream.make(1, 2, 3).pipe(
Stream.mapEffect((v) =>
Effect.all(
{
n1: Effect.succeed(v),
n2: Effect.succeed(v * 2),
n3: Effect.succeed(v * 3),
},
{ concurrency: "unbounded" },
),
),
)
Effect.runPromise(Stream.runCollect(stream)).then(console.log)
Unfortunately, this makes consuming stream slower because it has to wait for all effects to finalize for each element.
Seems like we are missing a Stream.all
What version of Effect is running?
3.6.0
What steps can reproduce the bug?
What is the expected behavior?
Passing more than 2 streams to
Stream.zip
works per documentation :What do you see instead?
when passing more than 2 streams to
Stream.zip
Additional information
No response