Bug 216035

Summary: [Win] The WPT server is not always starting when running layout tests
Product: WebKit Reporter: Per Arne Vollan <pvollan>
Component: Tools / TestsAssignee: Per Arne Vollan <pvollan>
Status: RESOLVED FIXED    
Severity: Normal CC: ap, bfulgham, ews-watchlist, glenn, gsnedders, jbedard, lingho, ryanhaddad, tsavell, webkit-bug-importer, youennf
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch none

Description Per Arne Vollan 2020-09-01 07:54:54 PDT
The Web platform test server is not always starting when running layout tests using Cygwin.
Comment 1 Per Arne Vollan 2020-09-01 08:02:33 PDT
Created attachment 407679 [details]
Patch
Comment 2 Per Arne Vollan 2020-09-01 09:00:03 PDT
Created attachment 407684 [details]
Patch
Comment 3 Alexey Proskuryakov 2020-09-01 09:42:29 PDT
Comment on attachment 407684 [details]
Patch

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

> Tools/ChangeLog:10
> +        issue by waiting up to 60 seconds with polling every 10th second. A unit test had to be modified, since it was overriding the

Why is it desirable to poll rarely? This will delay starting tests by 5 seconds on average.
Comment 4 Per Arne Vollan 2020-09-01 09:51:56 PDT
(In reply to Alexey Proskuryakov from comment #3)
> Comment on attachment 407684 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=407684&action=review
> 
> > Tools/ChangeLog:10
> > +        issue by waiting up to 60 seconds with polling every 10th second. A unit test had to be modified, since it was overriding the
> 
> Why is it desirable to poll rarely? This will delay starting tests by 5
> seconds on average.

Polling frequently seems to prevent the WPT server on Cygwin to start in a timely manner.

Perhaps it would be better to make this change Cygwin-only?
Comment 5 Alexey Proskuryakov 2020-09-01 10:18:02 PDT
Interesting. Or perhaps whatever prevents it from starting can be fixed. I don't know much about how the server works.
Comment 6 youenn fablet 2020-09-02 02:59:56 PDT
Comment on attachment 407684 [details]
Patch

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

>>> Tools/ChangeLog:10
>>> +        issue by waiting up to 60 seconds with polling every 10th second. A unit test had to be modified, since it was overriding the
>> 
>> Why is it desirable to poll rarely? This will delay starting tests by 5 seconds on average.
> 
> Polling frequently seems to prevent the WPT server on Cygwin to start in a timely manner.
> 
> Perhaps it would be better to make this change Cygwin-only?

I think it is ok to increase the timer for all platforms.
Increasing the polling time for Cygwin-only is probably fine as a stop-gap but we should try to understand why that happens.
@gsnedders might have an idea of how other CI are using WPT with Cygwin.
Comment 7 Sam Sneddon [:gsnedders] 2020-09-02 04:43:24 PDT
> @gsnedders might have an idea of how other CI are using WPT with Cygwin.

They aren't. Hence I don't really have any idea here!
Comment 8 Per Arne Vollan 2020-09-02 07:22:21 PDT
(In reply to Alexey Proskuryakov from comment #5)
> Interesting. Or perhaps whatever prevents it from starting can be fixed. I
> don't know much about how the server works.

I am not too familiar with the WPT server either :) I can look into why it appears to take longer time to start up on Windows. While that investigation is ongoing, I can upload a patch to extend the wait time for Cygwin only, so the affected bot(s) can resume running layout tests.

Thanks for reviewing!
Comment 9 Per Arne Vollan 2020-09-02 07:37:13 PDT
Created attachment 407763 [details]
Patch
Comment 10 Per Arne Vollan 2020-09-02 07:40:33 PDT
(In reply to youenn fablet from comment #6)
> Comment on attachment 407684 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=407684&action=review
> 
> >>> Tools/ChangeLog:10
> >>> +        issue by waiting up to 60 seconds with polling every 10th second. A unit test had to be modified, since it was overriding the
> >> 
> >> Why is it desirable to poll rarely? This will delay starting tests by 5 seconds on average.
> > 
> > Polling frequently seems to prevent the WPT server on Cygwin to start in a timely manner.
> > 
> > Perhaps it would be better to make this change Cygwin-only?
> 
> I think it is ok to increase the timer for all platforms.
> Increasing the polling time for Cygwin-only is probably fine as a stop-gap
> but we should try to understand why that happens.
> @gsnedders might have an idea of how other CI are using WPT with Cygwin.

As a stop-gap, I have uploaded a patch which only changes the behavior for Cygwin. I can investigate why the server startup time seems to be longer on Windows. I also seem to remember that WPT tests are quite slow on Windows. I am not sure if we reached a conclusion as to why, the last time we looked into this.

Thanks for reviewing!
Comment 11 Per Arne Vollan 2020-09-02 08:30:41 PDT
Comment on attachment 407763 [details]
Patch

I believe the GTK failures are unrelated to this patch.
Comment 12 EWS 2020-09-02 08:32:48 PDT
Committed r266460: <https://trac.webkit.org/changeset/266460>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 407763 [details].
Comment 13 Radar WebKit Bug Importer 2020-09-02 08:33:20 PDT
<rdar://problem/68211737>