- From: Benjamin Gruenbaum <notifications@github.com>
- Date: Thu, 16 Aug 2018 09:50:31 -0700
- To: whatwg/streams <streams@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/streams/issues/778/413612064@github.com>
> I think we should have auto-release. In a large code base using our own stream->to->async iterator transition we did this and are pretty happy with that as a default. > At least in tests we often check whether something's errored or closed by doing .getReader().closed.then(...); we shouldn't break that, I think. Definitely agree from our perspective. > I agree with auto-cancel as the default return() behavior. We also do this and find it quite useful. It is also easy to opt out of even without providing `.iterator({ preventCancel: true })` by either: - Wrapping the stream with another stream for the purpose of that iteration and not forwarding cancellation. - Wrapping the async iterator with another async iterator and not forwarding the `.return` there. That said, I am not objecting to a `.iterator({ preventCancel: true })` just saying that we haven't had to use it in our own code. ------ I've also been using async iterators with Node streams which have been working well - though I admit a lot less than I'd like to - I have been trying to (as in emailing relevant parties) solicit feedback but haven't been able to get it. We hope to solicit feedback through a Node.js foundation survey which we hope to send in about a month. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/whatwg/streams/issues/778#issuecomment-413612064
Received on Thursday, 16 August 2018 16:50:52 UTC