I have the following stream:
val stream: Process[Task, ByteVector] = ...
val s: Sink[Task, ByteVector] = sink.lift {
_ => Task.now(()) // does nothing for the purpose of this example
}
val hashedStream = scalaz.stream.writer.logged(stream).drainW(s.pipeIn(scalaz.stream.hash.sha1))
and it's failing on this assertion
It doesn't fail if I remove the writer. I think it's because scalaz.stream.hash.messageDigest emits on onComplete.
It seems there is a law that says that a process cannot emit after it's been killed. Where can I find scalaz-stream laws? Any help is appreciated.
Thanks,
Luciano.