Bug 239095 - REGRESSION (249029@main): http/wpt/cache-storage/cache-storage-networkprocess-crash.html is a flaky CRASH with ASSERTION FAILED: m_pageMap.isEmpty()
Summary: REGRESSION (249029@main): http/wpt/cache-storage/cache-storage-networkprocess...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Service Workers (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: youenn fablet
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-04-11 16:32 PDT by Truitt Savell
Modified: 2022-04-14 08:49 PDT (History)
4 users (show)

See Also:


Attachments
crash log (5.42 KB, text/plain)
2022-04-11 16:32 PDT, Truitt Savell
no flags Details
Patch (3.14 KB, patch)
2022-04-13 09:15 PDT, youenn fablet
no flags Details | Formatted Diff | Diff
Patch (3.14 KB, patch)
2022-04-13 23:20 PDT, youenn fablet
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Truitt Savell 2022-04-11 16:32:46 PDT
Created attachment 457298 [details]
crash log

Hardware:     	Macmini9,1
Architecture: 	arm64
OS:           	Monterey E
Style:        	debug
Flavor        	wk2
SDK:          	None
-----------------------------
Most recent failures:
249029: https://commits.webkit.org/249029@main
-----------------------------
Last success:
249027: https://commits.webkit.org/249027@main

http/wpt/cache-storage/cache-storage-networkprocess-crash.html

History:
https://results.webkit.org/?suite=layout-tests&test=http%2Fwpt%2Fcache-storage%2Fcache-storage-networkprocess-crash.html

log:
stderr:
MessageReceiveQueueMap::addImpl - adding duplicate any id receiver 20
ASSERTION FAILED: m_pageMap.isEmpty()
/Volumes/Data/worker/monterey-debug/build/Source/WebKit/WebProcess/WebProcess.cpp(877) : virtual bool WebKit::WebProcess::shouldTerminate()
1   0x152bd9ab4 WTFCrash
2   0x12bb55a60 std::__1::optional<std::__1::tuple<WTF::ObjectIdentifier<WebCore::PageIdentifierType>, WebKit::WebWheelEvent, WebCore::RectEdges<bool> > > IPC::Decoder::decode<std::__1::tuple<WTF::ObjectIdentifier<WebCore::PageIdentifierType>, WebKit::WebWheelEvent, WebCore::RectEdges<bool> > >()
3   0x12daae81c WebKit::WebProcess::shouldTerminate()
4   0x12d0694f0 WebKit::AuxiliaryProcess::enableTermination()

results:
Comment 1 Radar WebKit Bug Importer 2022-04-11 16:33:25 PDT
<rdar://problem/91595784>
Comment 2 Truitt Savell 2022-04-11 16:39:31 PDT
https://github.com/WebKit/WebKit/commit/47d33678ceceb0b0d38b8fda2d6ad7c7ba5aa266

this commit is close to the regression point for this test and seems like I could be related.
Comment 3 Truitt Savell 2022-04-11 16:45:53 PDT
Marked this test as failing while it is investigated.
Comment 4 Truitt Savell 2022-04-11 16:46:12 PDT
https://trac.webkit.org/changeset/292739/webkit
Comment 5 Ryan Haddad 2022-04-11 16:53:30 PDT
(In reply to Truitt Savell from comment #2)
> https://github.com/WebKit/WebKit/commit/
> 47d33678ceceb0b0d38b8fda2d6ad7c7ba5aa266
> 
> this commit is close to the regression point for this test and seems like I
> could be related.

https://commits.webkit.org/249022@main seems slightly more related, but I haven't tried to repro.
Comment 6 Alexey Proskuryakov 2022-04-12 14:28:48 PDT
The full crash log shows that it's in service worker code, so I'm going with https://commits.webkit.org/249029@main
Comment 7 youenn fablet 2022-04-13 08:29:39 PDT
It seems we are now calling WebSWContextManagerConnection::close multiple times, which  we should probably not.
Comment 8 youenn fablet 2022-04-13 09:15:59 PDT
Created attachment 457537 [details]
Patch
Comment 9 youenn fablet 2022-04-13 23:20:50 PDT
Created attachment 457596 [details]
Patch
Comment 10 EWS 2022-04-14 08:49:30 PDT
Committed r292869 (249640@main): <https://commits.webkit.org/249640@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 457537 [details].