Bug 263185

Summary: [PlayStation][win] fix assertions and WebDriverException when SingleWebProcess mode
Product: WebKit Reporter: haruhisa.shin <haruhisa.shin>
Component: WebKit2Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: kkinnunen, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Description haruhisa.shin 2023-10-15 23:08:19 PDT
The WebPageProxy::continueNavigationInNewProcess attempts to create a new WebProcess to continue processing a response from a particular website (e.g. Twitter, YouTube, Instagram, etc.).
In the case of SingleWebProcess mode, it tries to reuse an existing process instead of the above.
However some ASSERTs are written under the assumption that the process is newly created, so assertion failure occurs in debug builds.

Also, when a WebProcess switches, the old WebProcess disconnects the automationTarget, and then the new WebProcess reconnects.
In SingleWebProcess mode, this reconnection does not occur, resulting in WebDriverExcpetion.

To avoid this, I'll create a patch to prevent some assertions and automationTarget.disconnect() from being executed when in SingleWebProcess mode.
I would like your opinion on whether this change is appropriate.
Comment 1 haruhisa.shin 2023-10-16 00:30:14 PDT
Pull request: https://github.com/WebKit/WebKit/pull/19105
Comment 2 Radar WebKit Bug Importer 2023-10-22 23:09:14 PDT
<rdar://problem/117337565>
Comment 3 haruhisa.shin 2024-03-08 00:12:39 PST
I confirmed that the same problem occurs in wincairo, so I added [win] to the title.

Also, the patch I made before contained some unnecessary changes, so I improved it and made some additions and corrections to the commit log.

I would appreciate your review and opinion again.
Comment 4 EWS 2024-05-07 10:23:54 PDT
Committed 278467@main (5d53332466c2): <https://commits.webkit.org/278467@main>

Reviewed commits have been landed. Closing PR #19105 and removing active labels.