ReadableStream constructor handling of "pull" and "cancel" methods

RESOLVED FIXED in Firefox 65

Status

()

P2
normal
RESOLVED FIXED
4 months ago
4 months ago

People

(Reporter: jorendorff, Assigned: jorendorff)

Tracking

(Blocks: 1 bug)

unspecified
mozilla65
Points:
---

Firefox Tracking Flags

(firefox65 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

4 months ago
The spec says we should GetV the "pull" and "cancel" properties of the underlyingSource object only once, under the ReadableStream constructor, and the constructor should throw if either value isn't either callable or undefined.

https://streams.spec.whatwg.org/#rs-constructor
-> https://streams.spec.whatwg.org/#set-up-readable-stream-default-controller-from-underlying-source
-> https://streams.spec.whatwg.org/#create-algorithm-from-underlying-method

Currently we do none of this in the constructor, and we Get these properties like any other JS method call, each time we need to call them.

This causes test failures in several wpt-tests:
  testing/web-platform/tests/streams/readable-streams/
    bad-underlying-sources*.html
    constructor*.html
    general*.html
(Assignee)

Updated

4 months ago
Assignee: nobody → jorendorff

Comment 4

4 months ago
Pushed by jorendorff@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/345ad3e746e8
Fix ReadableStream constructor handling of "pull" and "cancel" methods. r=arai

Comment 6

4 months ago
Pushed by jorendorff@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/efcada818361
Fix ReadableStream constructor handling of "pull" and "cancel" methods. r=arai

Comment 7

4 months ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/efcada818361
Status: NEW → RESOLVED
Last Resolved: 4 months ago
status-firefox65: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla65
You need to log in before you can comment on or make changes to this bug.