You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Attempting to transfer wt.incomingUndirectionalStreams doesn't appear to work, as you say. When getReader() is called on the transferred readable stream of streams, the error is A ReadableStream could not be cloned because it was not transferred.
Sorry about this. Currently when a stream is transferred, the chunks that are passed through the stream are always cloned, never transferred. Since incomingUnidirectionalStreams is a stream of streams, each chunk is a stream, and streams can only be transferred, not cloned.
There was a plan to also support transferring the chunks (see Future Work) but without a concrete use case it never proceeded to the design stage.
whatwg/streams#1271 adds a new "owning" ReadableStream type, which allows for transferable chunks, albeit for a different purpose.
From #424 (comment) and #424 (comment):
whatwg/streams#1271 adds a new
"owning"
ReadableStream type, which allows for transferable chunks, albeit for a different purpose.@ricea would making incomingUnidirectionalStreams and incomingBidirectionalStreams
"owning"
solve theDataCloneError
, or is that a different part of the spec?The text was updated successfully, but these errors were encountered: