Bug 34281 - fast/workers/shared-worker-frame-lifecycle.html failed on Qt Bot
: fast/workers/shared-worker-frame-lifecycle.html failed on Qt Bot
Status: RESOLVED FIXED
Product: WebKit
Classification: Unclassified
Component: Tools / Tests
: 528+ (Nightly build)
: PC Mac OS X 10.5
: P2 Normal
Assigned To: Nobody
: Qt, QtTriaged
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-01-28 12:50 PST by Eric Seidel
Modified: 2011-05-24 10:22 PDT (History)
8 users (show)

See Also:


Attachments
patch (1.17 KB, patch)
2011-05-24 06:20 PDT, qi
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Seidel 2010-01-28 12:50:18 PST
fast/workers/shared-worker-frame-lifecycle.html failed on Qt Bot

Judging by the failure diff, i suspect the test just has a race:
http://build.webkit.org/results/Qt%20Linux%20Release/r53992%20(6638)/fast/workers/shared-worker-frame-lifecycle-diffs.txt
--- /home/webkit/buildslave/qt-linux-release/build/layout-test-results/fast/workers/shared-worker-frame-lifecycle-expected.txt	2010-01-28 01:25:03.000000000 -0800
+++ /home/webkit/buildslave/qt-linux-release/build/layout-test-results/fast/workers/shared-worker-frame-lifecycle-actual.txt	2010-01-28 01:25:03.000000000 -0800
@@ -1,12 +1,3 @@
-This test checks whether shared workers exit when the parent document closes
-
-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-
-
-PASS Frame1 closed, shared workers kept running
-PASS Frame2 closed, shared worker2 exited
-PASS Frame3 closed, shared worker3 exited
-PASS Frame4 closed, all workers closed
-
-TEST COMPLETE
+CONSOLE MESSAGE: line 19: TypeError: Result of expression 'document.getElementById("console")' [null] is not an object.
+FAIL: Timed out waiting for notifyDone to be called
 
Has been around 5 months:
http://trac.webkit.org/browser/trunk/LayoutTests/fast/workers/shared-worker-frame-lifecycle.html
Comment 1 Andrew Wilson 2010-01-28 14:15:21 PST
I'm hard-pressed to understand how this happens - here's the body of the test:

<head>
<link rel="stylesheet" href="../js/resources/js-test-style.css">
<script src="../js/resources/js-test-pre.js"></script>
</head>
<body>
<p id="description"></p>
<div id="console"></div>
<script src="resources/shared-worker-create-common.js"></script>
<script src="resources/worker-util.js"></script>
<script src="resources/shared-worker-lifecycle.js"></script>
</body>


The error is generated by line 19 of js-test-pre.js (the "debug()" method). Note that the "console" div is defined before any of the test code executes, so there's no way for debug() to get invoked before console is defined.

If this keeps happening, we could move the loading of the js-test-pre.js script until after the console div is defined, but it shouldn't matter.
Comment 2 Eric Seidel 2010-01-28 18:08:30 PST
I believe scripts execute as soon as they're loaded.  So it's possible for js-test-pre.js to execute before <div id="console"> is hit.  But looking at it, I don't see it using debug() anywhere in the global scope which could cause this error.
Comment 3 Andrew Wilson 2010-01-28 18:19:41 PST
Exactly. debug() has to get called, and I can't see how it would get called without actually running a test.
Comment 4 Csaba Osztrogonác 2010-02-04 02:52:26 PST
$WebKitTools/Scripts/run-webkit-tests fast/workers/shared-worker-frame-lifecycle.html --iterations 10000
--> always passed

$WebKitTools/Scripts/run-webkit-tests fast/workers --iterations 100
--> failed 7 times, passed 93 times

This strange bug might caused by another test, it can be a DRT sideeffect, but I can't reproduce it consistently yet. So I skipped it to make buildbot happy. ( http://trac.webkit.org/changeset/54338 )
Comment 5 Csaba Osztrogonác 2011-03-16 04:10:09 PDT
I skipped it again, because it still fails: http://trac.webkit.org/changeset/81226

100 runs, 14 fails
Comment 6 Csaba Osztrogonác 2011-03-16 04:18:06 PDT
(In reply to comment #5)
> I skipped it again, because it still fails: http://trac.webkit.org/changeset/81226
> 
> 100 runs, 14 fails

pretty diff: http://build.webkit.org/results/Qt%20Linux%20Release/r81232%20%2829888%29/fast/workers/shared-worker-frame-lifecycle-pretty-diff.html
Comment 7 qi 2011-05-24 05:58:27 PDT
It works for me on the r87070. I used "Tools/Scripts/run-webkit-tests fast/workers --iterations 100".

Can we just unskip it?
Comment 8 Csaba Osztrogonác 2011-05-24 06:00:57 PDT
(In reply to comment #7)
> It works for me on the r87070. I used "Tools/Scripts/run-webkit-tests fast/workers --iterations 100".
> 
> Can we just unskip it?

Thanks for checking it. rs=me for unskipping it.
We can skip it again if fail occurs again. :)
Comment 9 qi 2011-05-24 06:20:42 PDT
Created attachment 94600 [details]
patch

Remove the test case from skip list.
Comment 10 Andreas Kling 2011-05-24 06:22:26 PDT
Comment on attachment 94600 [details]
patch

rs=me
Comment 11 WebKit Commit Bot 2011-05-24 08:43:16 PDT
The commit-queue encountered the following flaky tests while processing attachment 94600 [details]:

animations/dynamic-stylesheet-loading.html bug 52669 (authors: cmarrin@apple.com and simon.fraser@apple.com)
http/tests/websocket/tests/url-no-trailing-slash.html bug 60906 (author: abarth@webkit.org)
The commit-queue is continuing to process your patch.
Comment 12 WebKit Commit Bot 2011-05-24 08:45:02 PDT
Comment on attachment 94600 [details]
patch

Clearing flags on attachment: 94600

Committed r87155: <http://trac.webkit.org/changeset/87155>
Comment 13 WebKit Commit Bot 2011-05-24 08:45:09 PDT
All reviewed patches have been landed.  Closing bug.
Comment 14 WebKit Commit Bot 2011-05-24 10:22:57 PDT
The commit-queue encountered the following flaky tests while processing attachment 94600 [details]:

java/lc3/JavaObject/JavaObjectToByte-006.html bug 60333 (author: ap@webkit.org)
The commit-queue is continuing to process your patch.