Bug 198666 - New Layout Test landed flaky [Mac WK1] resize-observer/element-leak.html is a flaky failure
Summary: New Layout Test landed flaky [Mac WK1] resize-observer/element-leak.html is a...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: cathiechen
URL:
Keywords: InRadar
: 198667 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-06-07 10:48 PDT by Shawn Roberts
Modified: 2019-06-19 03:58 PDT (History)
10 users (show)

See Also:


Attachments
Archive of layout-test-results from webkit-cq-02 (3.07 MB, application/zip)
2019-06-07 17:47 PDT, WebKit Commit Bot
no flags Details
Patch (1.92 KB, patch)
2019-06-07 22:30 PDT, cathiechen
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews215 for win-future (13.48 MB, application/zip)
2019-06-07 23:55 PDT, EWS Watchlist
no flags Details
Patch (1.98 KB, patch)
2019-06-19 02:40 PDT, cathiechen
no flags Details | Formatted Diff | Diff
Patch (1.98 KB, patch)
2019-06-19 02:50 PDT, cathiechen
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Shawn Roberts 2019-06-07 10:48:14 PDT
The following layout test is flaky on Mac WK1 Release

resize-observer/element-leak.html

Probable cause:

New test added in r246057 is a flaky failure on Mac WK1 Release runs

Verified locally with :

run-webkit-tests resize-observer/element-leak.html --iter 500 -f -1

Flakiness Dashboard:

https://webkit-test-results.webkit.org/dashboards/flakiness_dashboard.html#showAllRuns=true&tests=resize-observer%2Felement-leak.html

--- /Volumes/Data/slave/mojave-release-tests-wk1/build/layout-test-results/resize-observer/element-leak-expected.txt
+++ /Volumes/Data/slave/mojave-release-tests-wk1/build/layout-test-results/resize-observer/element-leak-actual.txt
@@ -1,4 +1,4 @@
 
 PASS ResizeObserver implemented 
-PASS Test elements leak 
+FAIL Test elements leak promise_test: Unhandled rejection with value: "Test timed out"
Comment 1 Alexey Proskuryakov 2019-06-07 13:28:20 PDT
*** Bug 198667 has been marked as a duplicate of this bug. ***
Comment 2 Ryosuke Niwa 2019-06-07 15:43:45 PDT
Maybe GC is too slow in WebKit1? Maybe we just need to skip the test in WK1.
Comment 3 WebKit Commit Bot 2019-06-07 17:47:58 PDT
The commit-queue just saw resize-observer/element-leak.html flake (text diff) while processing attachment 371632 [details] on bug 198681.
Bot: webkit-cq-02  Port: <class 'webkitpy.common.config.ports.MacPort'>  Platform: Mac OS X 10.13.6
Comment 4 WebKit Commit Bot 2019-06-07 17:47:59 PDT
Created attachment 371636 [details]
Archive of layout-test-results from webkit-cq-02
Comment 5 cathiechen 2019-06-07 22:07:31 PDT
Looks like it took very long time to construct iframes which create 1000 div and remove.
I'll reduce the div number. We don't need 1000 div to confirm the GC problem.
Comment 6 cathiechen 2019-06-07 22:30:44 PDT
Created attachment 371647 [details]
Patch
Comment 7 EWS Watchlist 2019-06-07 23:55:16 PDT
Comment on attachment 371647 [details]
Patch

Attachment 371647 [details] did not pass win-ews (win):
Output: https://webkit-queues.webkit.org/results/12416260

New failing tests:
fast/block/float/float-with-anonymous-previous-sibling.html
Comment 8 EWS Watchlist 2019-06-07 23:55:18 PDT
Created attachment 371649 [details]
Archive of layout-test-results from ews215 for win-future

The attached test failures were seen while running run-webkit-tests on the win-ews.
Bot: ews215  Port: win-future  Platform: CYGWIN_NT-10.0-17763-3.0.5-338.x86_64-x86_64-64bit
Comment 9 cathiechen 2019-06-08 14:17:17 PDT
(In reply to Build Bot from comment #7)
> Comment on attachment 371647 [details]
> Patch
> 
> Attachment 371647 [details] did not pass win-ews (win):
> Output: https://webkit-queues.webkit.org/results/12416260
> 
> New failing tests:
> fast/block/float/float-with-anonymous-previous-sibling.html

This is not related to the patch.
Comment 10 Frédéric Wang (:fredw) 2019-06-19 00:40:05 PDT
Comment on attachment 371647 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=371647&action=review

> LayoutTests/ChangeLog:9
> +        We don't need 1000 element to confirm the GC problem. So in order to reduce the fake alarm.

1000 elements*
There should be a comma at the end of the line.
What is the "fake alarm", a timeout?

> LayoutTests/resize-observer/resources/element-leak-frame.html:18
> +var container = document.createElement('p');

p's content model is "phrasing content", so it is not valid to put a div element inside.
https://html.spec.whatwg.org/multipage/grouping-content.html#the-p-element

You can make container a div instead.

> LayoutTests/resize-observer/resources/element-leak-frame.html:23
> +document.body.appendChild(container);

I don't know if this change is necessary, but it should be explained in the ChangeLog.
Comment 11 cathiechen 2019-06-19 02:38:48 PDT
Comment on attachment 371647 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=371647&action=review

Hi Fred,

Thanks for the review.

>> LayoutTests/ChangeLog:9
>> +        We don't need 1000 element to confirm the GC problem. So in order to reduce the fake alarm.
> 
> 1000 elements*
> There should be a comma at the end of the line.
> What is the "fake alarm", a timeout?

Done. Yes, it's a timeout.

>> LayoutTests/resize-observer/resources/element-leak-frame.html:18
>> +var container = document.createElement('p');
> 
> p's content model is "phrasing content", so it is not valid to put a div element inside.
> https://html.spec.whatwg.org/multipage/grouping-content.html#the-p-element
> 
> You can make container a div instead.

Done.

>> LayoutTests/resize-observer/resources/element-leak-frame.html:23
>> +document.body.appendChild(container);
> 
> I don't know if this change is necessary, but it should be explained in the ChangeLog.

Done. This change could reduce the times to modify DOM tree directly.
Comment 12 cathiechen 2019-06-19 02:40:22 PDT
Created attachment 372449 [details]
Patch
Comment 13 cathiechen 2019-06-19 02:50:32 PDT
Created attachment 372450 [details]
Patch
Comment 14 WebKit Commit Bot 2019-06-19 03:54:18 PDT
Comment on attachment 372450 [details]
Patch

Clearing flags on attachment: 372450

Committed r246584: <https://trac.webkit.org/changeset/246584>
Comment 15 WebKit Commit Bot 2019-06-19 03:54:20 PDT
All reviewed patches have been landed.  Closing bug.
Comment 16 Radar WebKit Bug Importer 2019-06-19 03:58:14 PDT
<rdar://problem/51890002>