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
The test is invalid in that it makes some assumption about non deterministic behaviour.
The current expected flow of the test is as follow:
Append data to a source buffer; this will fire the “update” event.
The update event is fired, the event listener calls sourcebuffer.abort() which will fire the event “abort” followed “updateend” (https://w3c.github.io/media-source/#dom-sourcebuffer-abort steps 4.3 and 4.4)
An updateend event listener is set that will call MediaSource.endOfStream()
—
Now the issue at hand is that there’s no guarantee that when the “update” event listener runs the updateend event hasn’t already been queued from the original appendBuffer operation (the processing of the source buffer is asynchronous as per https://w3c.github.io/media-source/#dom-sourcebuffer-appendbuffer step 5)
If that happens two updateend events will be fired.
The first updateend listener will call MediaSource.endOfStream() which set the MediaSource readyState as “ended”.
If a 2nd updateend is fired then MediaSource.endOfStream() will be run again.
wpt/media-source/SourceBuffer-abort-updating.html
Line 55 in b4c50ee
The test is invalid in that it makes some assumption about non deterministic behaviour.
The current expected flow of the test is as follow:
Append data to a source buffer; this will fire the “update” event.
The update event is fired, the event listener calls sourcebuffer.abort() which will fire the event “abort” followed “updateend” (https://w3c.github.io/media-source/#dom-sourcebuffer-abort steps 4.3 and 4.4)
An updateend event listener is set that will call MediaSource.endOfStream()
—
Now the issue at hand is that there’s no guarantee that when the “update” event listener runs the updateend event hasn’t already been queued from the original appendBuffer operation (the processing of the source buffer is asynchronous as per https://w3c.github.io/media-source/#dom-sourcebuffer-appendbuffer step 5)
If that happens two updateend events will be fired.
The first updateend listener will call MediaSource.endOfStream() which set the MediaSource readyState as “ended”.
If a 2nd updateend is fired then MediaSource.endOfStream() will be run again.
Per spec:
https://w3c.github.io/media-source/#dom-mediasource-endofstream
“If the readyState attribute is not in the "open" state then throw an InvalidStateError exception and abort these steps.”
If this happens the test will fail with "The object is in an invalid state."
This test is disabled in Mozilla's test suite: https://bugzilla.mozilla.org/show_bug.cgi?id=1288343#c10
As well as in WebKit for those reasons.
The text was updated successfully, but these errors were encountered: