Closed Bug 1604375 Opened 5 years ago Closed 5 years ago

The ReadableStreamTee algorithm isn't up-to-date with the spec

Categories

(Core :: JavaScript: Standard Library, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla74
Tracking Status
firefox74 --- fixed

People

(Reporter: Waldo, Assigned: Waldo)

References

(Blocks 1 open bug)

Details

Attachments

(5 files)

Our ReadableStreamTee algorithm doesn't match the current spec -- ours doesn't have a reading variable, our ReadableStreamTee_Pull bears not much relation to the current algorithm, etc. I'm going to update it to current spec. (I don't know how observable our differences from the current spec are. It's at least possible the distinctions are editorial, but the extent of differences in the pull algorithm suggests otherwise to me.)

(This also has the side effect of familiarizing me with the tactics used to implement teeing, tactics that I expect should carry over to implementation tactics for implementing ReadableStream.prototype.pipeTo.)

https://github.com/whatwg/streams/commit/6f94580f6731d1e017c516af097d47c45aad1f56 appears to be much of the difference between our algorithm and the current algorithm, and the changes made there are not merely editorial. So the issues to fix here are observable.

Most of a patch done, but https://treeherder.mozilla.org/#/jobs?repo=try&revision=8e256851af7b83156e213df10dc2290ac7c80618 suggests a wpt update is needed, or wpt tests are out of date, or something unobvious is up. Still need to investigate.

Assignee: nobody → jwalden
Status: NEW → ASSIGNED
Pushed by jwalden@mit.edu: https://hg.mozilla.org/integration/autoland/rev/0374840e1484 Rename |SetPromiseIsHandled| to |SetSettledPromiseIsHandled|, as the function can only be used on settled promises. r=arai https://hg.mozilla.org/integration/autoland/rev/77f8c50c3a5f Rename |RunResolutionFunction| to |RunSettlingFunction|, because "resolution" is sort of like "resolve" but this function handles both resolve and reject functions so it's misnomerish. r=arai https://hg.mozilla.org/integration/autoland/rev/677c66a198eb Split |RunSettlingFunction| into |RunFulfillFunction| and |RunRejectFunction|. r=arai https://hg.mozilla.org/integration/autoland/rev/e37d4d3ab131 Implement |JS::AddPromiseReactionsIgnoringUnhandledRejection| that won't report an unhandled rejection if the passed-in-promise rejects. r=arai https://hg.mozilla.org/integration/autoland/rev/ba76b651e79f Update |ReadableStreamTee| to latest spec. r=arai
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: