RESOLVED FIXED 148320
Layout Test streams/reference-implementation/readable-stream.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=148320
Summary Layout Test streams/reference-implementation/readable-stream.html is flaky
Tim Horton
Reported 2015-08-21 12:17:29 PDT
The following layout test recently started flaking on Mac: streams/reference-implementation/readable-stream.html See: https://webkit-test-results.webkit.org/dashboards/flakiness_dashboard.html#showAllRuns=true&tests=streams%2Freference-implementation%2Freadable-stream.html
Attachments
Patch (2.11 KB, patch)
2015-08-24 09:21 PDT, Xabier Rodríguez Calvar
no flags
Patch (4.41 KB, patch)
2015-08-24 16:30 PDT, Xabier Rodríguez Calvar
no flags
Patch for landing (3.91 KB, patch)
2015-08-28 01:55 PDT, Xabier Rodríguez Calvar
no flags
Tim Horton
Comment 1 2015-08-21 12:17:55 PDT
Youenn, this looks like a feature you've been working on. Any ideas why this might have recently started flaking?
youenn fablet
Comment 2 2015-08-21 12:41:45 PDT
Tim, thanks for spotting these flakiness. Calvaris, it seems the changes brought on the tests when inverting the order of the promise resolution have some bad effects. Will you have some time to check these?
Xabier Rodríguez Calvar
Comment 3 2015-08-24 01:09:47 PDT
(In reply to comment #2) > Tim, thanks for spotting these flakiness. > Calvaris, it seems the changes brought on the tests when inverting the order > of the promise resolution have some bad effects. Will you have some time to > check these? Sure, I'm on it now.
Xabier Rodríguez Calvar
Comment 4 2015-08-24 09:21:24 PDT
Created attachment 259755 [details] Patch It is true that timeout hitting earlier happens a bit more often after the promise changes but it was already happening before aparently. Let's try to increase the timeout and see if the problem disappears.
youenn fablet
Comment 5 2015-08-24 11:05:42 PDT
(In reply to comment #4) > Created attachment 259755 [details] > Patch > > It is true that timeout hitting earlier happens a bit more often after the > promise changes but it was already happening before aparently. Let's try to > increase the timeout and see if the problem disappears. Then, maybe we could rewrite the test cases a bit to reduce the flakiness probability. In particular we could call setTimeout at the latest time. For instance, in test 6, we could move the call to setTimeout within startPromise.then() callback.
Xabier Rodríguez Calvar
Comment 6 2015-08-24 16:30:11 PDT
Created attachment 259791 [details] Patch Set timeouts later as suggested by Youenn. I thought of that too but I was reluctant because we'd lose the structure of the original reference test, but I decided to add a comment to help with that.
Xabier Rodríguez Calvar
Comment 7 2015-08-27 09:52:44 PDT
This flakiness seemed important. Can we get this reviewed?
Alexey Proskuryakov
Comment 8 2015-08-27 10:30:20 PDT
Comment on attachment 259791 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=259791&action=review Sad, but looks like there is no other way to test for this. > LayoutTests/streams/reference-implementation/readable-stream.html:273 > + // In the original test this timeout is outside the promise fulfillment callback, but it makes test flakier so > + // we better move it inside here. This comment is not helpful without a reference to original. Are we modifying a W3C test here? I would just remove the comment (and other copies of it) unless there is a really important reason for it - otherwise anyone interested can just blame the source to see history.
youenn fablet
Comment 9 2015-08-27 13:44:15 PDT
If feasible, one option might be to backport these changes to the reference tests.
Xabier Rodríguez Calvar
Comment 10 2015-08-28 01:55:03 PDT
Created attachment 260141 [details] Patch for landing
Xabier Rodríguez Calvar
Comment 11 2015-08-28 01:55:53 PDT
(In reply to comment #9) > If feasible, one option might be to backport these changes to the reference > tests. I'll propose the change, let's see if Domenic accepts it.
WebKit Commit Bot
Comment 12 2015-08-28 02:48:59 PDT
Comment on attachment 260141 [details] Patch for landing Clearing flags on attachment: 260141 Committed r189093: <http://trac.webkit.org/changeset/189093>
WebKit Commit Bot
Comment 13 2015-08-28 02:49:02 PDT
All reviewed patches have been landed. Closing bug.
Xabier Rodríguez Calvar
Comment 14 2015-08-28 03:03:07 PDT
(In reply to comment #11) > (In reply to comment #9) > > If feasible, one option might be to backport these changes to the reference > > tests. > > I'll propose the change, let's see if Domenic accepts it. Done: https://github.com/whatwg/streams/pull/392
Note You need to log in before you can comment on or make changes to this bug.