Bug 184058

Summary: REGRESSION (r229831?): LayoutTest storage/indexeddb/dont-wedge-private.html is a flaky failure
Product: WebKit Reporter: Ryan Haddad <ryanhaddad>
Component: New BugsAssignee: Brady Eidson <beidson>
Status: RESOLVED FIXED    
Severity: Normal CC: aestes, alecflett, beidson, cdumez, commit-queue, ews-watchlist, jsbell, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Description Ryan Haddad 2018-03-27 16:25:04 PDT
The following layout test is flaky on iOS and macOS

storage/indexeddb/dont-wedge-private.html

Probable cause:

Unknown, this test became flaky within the last 7 days.

Flakiness Dashboard:

https://webkit-test-results.webkit.org/dashboards/flakiness_dashboard.html#showAllRuns=true&tests=storage%2Findexeddb%2Fdont-wedge-private.html

--- /Volumes/Data/slave/sierra-debug-tests-wk2/build/layout-test-results/storage/indexeddb/dont-wedge-private-expected.txt
+++ /Volumes/Data/slave/sierra-debug-tests-wk2/build/layout-test-results/storage/indexeddb/dont-wedge-private-actual.txt
@@ -10,7 +10,6 @@
 
 deleteDatabase1():
 indexedDB.deleteDatabase(dbname1)
-In a multi process implementation this deleteDatabase may be blocked temporarily, so we don't check for either the presence or absence of a blocked event.
 
 deleteDatabase2():
 indexedDB.deleteDatabase(dbname2)
@@ -24,8 +23,9 @@
 store1.put(0, 0)
 
 openOnSuccess1():
-PASS isAfterReload() is true
+FAIL isAfterReload() should be true. Was false.
 PASS successfullyParsed is true
+Some tests failed.
 
 TEST COMPLETE
Comment 1 Ryan Haddad 2018-03-27 16:33:58 PDT
Based on when this started, this could be more fallout from https://trac.webkit.org/changeset/229831/webkit
Comment 2 Radar WebKit Bug Importer 2018-03-28 15:41:13 PDT
<rdar://problem/38975304>
Comment 3 Brady Eidson 2018-05-16 13:56:20 PDT
This test is pretty straight forward, as far as IDB tests go.

It's somewhat surprising that it has this failure mode.

It is interesting that dont-wedge-private has the problem but not dont-wedge

This suggests to me it's an aspect of the in-process, in-memory private store.

Perhaps this store is synchronous enough to actually allow the open request to finish before the reload takes place. 

Though that would be some what surprising... I suppose I can try to verify*

* - That will be hard because I have been wholly unable to reproduce locally.
Comment 4 Brady Eidson 2018-05-16 15:49:53 PDT
(In reply to Brady Eidson from comment #3)
> This test is pretty straight forward, as far as IDB tests go.
> 
> It's somewhat surprising that it has this failure mode.
> 
> It is interesting that dont-wedge-private has the problem but not dont-wedge
> 
> This suggests to me it's an aspect of the in-process, in-memory private
> store.
> 
> Perhaps this store is synchronous enough to actually allow the open request
> to finish before the reload takes place. 
> 
> Though that would be some what surprising... I suppose I can try to verify*
> 
> * - That will be hard because I have been wholly unable to reproduce locally.

I'm going to land a speculative fix to the test that makes the asynchronous database activity take MANY MANY more spins of the runloop, reliably so.

That should give the location change a chance to always take place first.
Comment 5 Brady Eidson 2018-05-16 15:55:31 PDT
Created attachment 340534 [details]
Patch
Comment 6 WebKit Commit Bot 2018-05-16 17:33:39 PDT
Comment on attachment 340534 [details]
Patch

Clearing flags on attachment: 340534

Committed r231880: <https://trac.webkit.org/changeset/231880>
Comment 7 WebKit Commit Bot 2018-05-16 17:33:41 PDT
All reviewed patches have been landed.  Closing bug.