Bug 188389 - Avoid timeout resulted from calling waitUntilDone when test is not running
Summary: Avoid timeout resulted from calling waitUntilDone when test is not running
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sihui Liu
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-08-07 13:56 PDT by Sihui Liu
Modified: 2018-08-13 15:17 PDT (History)
6 users (show)

See Also:


Attachments
Patch (1.67 KB, patch)
2018-08-07 14:01 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Patch (1.65 KB, patch)
2018-08-07 19:19 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Patch (1.63 KB, patch)
2018-08-09 11:22 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Patch (1.64 KB, patch)
2018-08-09 12:01 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews107 for mac-sierra-wk2 (3.05 MB, application/zip)
2018-08-09 12:54 PDT, EWS Watchlist
no flags Details
Patch for landing (1.63 KB, patch)
2018-08-13 14:37 PDT, Sihui Liu
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sihui Liu 2018-08-07 13:56:29 PDT
If the test is not running(already done), we should not set waitUntilDone flag, because this could make subsequent tests timeout.
Comment 1 Sihui Liu 2018-08-07 14:01:18 PDT
Created attachment 346727 [details]
Patch
Comment 2 Chris Dumez 2018-08-07 14:05:32 PDT
Comment on attachment 346727 [details]
Patch

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

> Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
> +    if (!injectedBundle.isTestRunning())

Could this be an assertion? Presumably, it is the test that is written badly in this case.
Comment 3 Alexey Proskuryakov 2018-08-07 14:28:29 PDT
Comment on attachment 346727 [details]
Patch

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

>> Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
>> +    if (!injectedBundle.isTestRunning())
> 
> Could this be an assertion? Presumably, it is the test that is written badly in this case.

Yes, I think that a release assert would be appropriate.
Comment 4 Sihui Liu 2018-08-07 19:19:23 PDT
Created attachment 346750 [details]
Patch
Comment 5 Sihui Liu 2018-08-07 19:19:58 PDT
(In reply to Chris Dumez from comment #2)
> Comment on attachment 346727 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=346727&action=review
> 
> > Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
> > +    if (!injectedBundle.isTestRunning())
> 
> Could this be an assertion? Presumably, it is the test that is written badly
> in this case.

Done.
Comment 6 Chris Dumez 2018-08-07 20:09:30 PDT
Comment on attachment 346750 [details]
Patch

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

> Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
> +    ASSERT(!injectedBundle.isTestRunning());

This assertion looks wrong / resersed. Please run layout tests in debug locally to make sure your assertion does not hit as we do not have wk2 debug configuration on EWS.
Comment 7 Sihui Liu 2018-08-08 09:20:10 PDT
(In reply to Chris Dumez from comment #6)
> Comment on attachment 346750 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=346750&action=review
> 
> > Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
> > +    ASSERT(!injectedBundle.isTestRunning());
> 
> This assertion looks wrong / resersed. Please run layout tests in debug
> locally to make sure your assertion does not hit as we do not have wk2 debug
> configuration on EWS.

Oops..it is reversed. I am running the layout tests locally, will upload patch after verification. Thanks!
Comment 8 Alexey Proskuryakov 2018-08-08 09:22:10 PDT
Comment on attachment 346750 [details]
Patch

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

>>> Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
>>> +    ASSERT(!injectedBundle.isTestRunning());
>> 
>> This assertion looks wrong / resersed. Please run layout tests in debug locally to make sure your assertion does not hit as we do not have wk2 debug configuration on EWS.
> 
> Oops..it is reversed. I am running the layout tests locally, will upload patch after verification. Thanks!

But also, please make it a *release* assert. There is no reason why we would only want to catch this situation in debug builds.
Comment 9 Sihui Liu 2018-08-09 11:22:03 PDT
Created attachment 346850 [details]
Patch
Comment 10 Chris Dumez 2018-08-09 11:32:35 PDT
Comment on attachment 346850 [details]
Patch

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

> Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
> +    ASSERT(injectedBundle.isTestRunning());

Alexey asked for a release assertion.
Comment 11 Sihui Liu 2018-08-09 12:01:19 PDT
Created attachment 346854 [details]
Patch
Comment 12 Sihui Liu 2018-08-09 12:01:38 PDT
(In reply to Chris Dumez from comment #10)
> Comment on attachment 346850 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=346850&action=review
> 
> > Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:189
> > +    ASSERT(injectedBundle.isTestRunning());
> 
> Alexey asked for a release assertion.


Forgot to add that after local layout tests done. Uploading again...
Comment 13 Chris Dumez 2018-08-09 12:02:28 PDT
Comment on attachment 346854 [details]
Patch

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

r=me if Mac-wk2 EWS is green.

> Tools/ChangeLog:6
> +        If test is not running, we should not set the waitUntilDone flag, or it may cause subsequent tests timeout.

This should come *after* the Reviewed by line.
Comment 14 EWS Watchlist 2018-08-09 12:54:47 PDT
Comment on attachment 346854 [details]
Patch

Attachment 346854 [details] did not pass mac-wk2-ews (mac-wk2):
Output: https://webkit-queues.webkit.org/results/8811097

New failing tests:
css3/filters/backdrop/add-remove-add-backdrop-filter.html
Comment 15 EWS Watchlist 2018-08-09 12:54:49 PDT
Created attachment 346856 [details]
Archive of layout-test-results from ews107 for mac-sierra-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews107  Port: mac-sierra-wk2  Platform: Mac OS X 10.12.6
Comment 16 Sihui Liu 2018-08-13 14:37:22 PDT
Created attachment 347039 [details]
Patch for landing
Comment 17 WebKit Commit Bot 2018-08-13 15:16:47 PDT
Comment on attachment 347039 [details]
Patch for landing

Clearing flags on attachment: 347039

Committed r234819: <https://trac.webkit.org/changeset/234819>
Comment 18 WebKit Commit Bot 2018-08-13 15:16:49 PDT
All reviewed patches have been landed.  Closing bug.
Comment 19 Radar WebKit Bug Importer 2018-08-13 15:17:22 PDT
<rdar://problem/43255316>