Bug 233783 - Regression(r283179) Google Drive freezes after downloading a folder
Summary: Regression(r283179) Google Drive freezes after downloading a folder
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks: 230812
  Show dependency treegraph
 
Reported: 2021-12-02 14:27 PST by Chris Dumez
Modified: 2021-12-02 20:37 PST (History)
6 users (show)

See Also:


Attachments
Patch (10.38 KB, patch)
2021-12-02 14:34 PST, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2021-12-02 14:27:12 PST
Google Drive freezes after downloading a folder since r283179.
Comment 1 Chris Dumez 2021-12-02 14:27:27 PST
<rdar://85918531>
Comment 2 Chris Dumez 2021-12-02 14:34:30 PST
Created attachment 445773 [details]
Patch
Comment 3 Darin Adler 2021-12-02 16:41:37 PST
Comment on attachment 445773 [details]
Patch

Regression test?
Comment 4 Chris Dumez 2021-12-02 16:42:34 PST
(In reply to Darin Adler from comment #3)
> Comment on attachment 445773 [details]
> Patch
> 
> Regression test?

Hmm. Maybe if I add an SPI to ask if the layer tree is frozen or not. I'll look into that.
Comment 5 Geoffrey Garen 2021-12-02 16:54:59 PST
r=me

Would this behavior be simpler if we fired decidePolicyForNavigationResponse before parsing the COOP header and trying to load in a separate process? It seems a little round-about to receive the response, launch a new process, *and then* ask the client if that's what it wanted.
Comment 6 Chris Dumez 2021-12-02 17:07:25 PST
(In reply to Geoffrey Garen from comment #5)
> r=me
> 
> Would this behavior be simpler if we fired decidePolicyForNavigationResponse
> before parsing the COOP header and trying to load in a separate process? It
> seems a little round-about to receive the response, launch a new process,
> *and then* ask the client if that's what it wanted.

The reason this was done this way is that decidePolicyForNavigationResponse() currently comes from the WebProcess to the UIProcess and contains the network resource. For security reasons, we do not want the old process to see the response from the navigated-to page that has opted into COOP and caused a process-swap.

In the future, we may want to consider doing decidePolicyForNavigationResponse() directly from the network process to the UIProcess. We would also need to have the UIProcess trigger the download instead of sending PolicyAction::Download to the WebProcess.
Comment 7 Chris Dumez 2021-12-02 20:31:45 PST
Will look into adding an API test tomorrow via Bug 233798.
Comment 8 EWS 2021-12-02 20:37:42 PST
Committed r286479 (244818@main): <https://commits.webkit.org/244818@main>

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