New issue
Advanced search Search tips

Issue 651818 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug



Sign in to add a comment

Open requests are canceled when trying to saving the page

Reported by denis.tr...@unblu.com, Sep 30 2016

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.116 Safari/537.36

Example URL:

Steps to reproduce the problem:
1. Open a page, which does a long pending xhr request
2. Press ctrl+s or "save page as..." button to save the page
3. The pending request is canceled by the browser

What is the expected behavior?
The browser should not cancel any request, when saving the page.

What went wrong?
The browser cancels any open request, when trying to save a page. This causes any page to break, which uses a lot of dynamic content.
Especially pages which use long polling requests to "push" data from server to client do not work anymore after saving the page

Did this work before? N/A 

Chrome version: 53.0.2785.116  Channel: stable
OS Version: 10.0
Flash Version: Shockwave Flash 23.0 r0
 

Comment 1 by woxxom@gmail.com, Sep 30 2016

Probably related to issue 649875
Components: -Internals>Network UI>Browser>Offline
I was able to reproduce the issue. It seems like after the user uses "save page as" to save the page, the URL_Requests are set with FILTER_TYPE_GZIP and the delegate info was ResourceScheduler. My guess would be if that happens, the response won't be used to load the webpage. 

Comment 3 by dim...@chromium.org, Oct 12 2016

Components: -UI>Browser>Offline UI>Browser>Downloads
This is SaveAs issue on WIndows, changing component.
Cc: lukasza@chromium.org
Components: Blink>SavePage
Labels: -OS-Windows -Pri-2 OS-All Pri-3
Status: Available (was: Unconfirmed)
Pending requests are explicitly cancelled prior to starting a Save As operation. lukasza: Do you know if that requirement can be relaxed?
Project Member

Comment 5 by sheriffbot@chromium.org, Dec 11 2017

Labels: Hotlist-Recharge-Cold
Status: Untriaged (was: Available)
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue.

Sorry for the inconvenience if the bug really should have been left as Available. If you change it back, also remove the "Hotlist-Recharge-Cold" label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
lukasza@ just checking in on #4.  Thanks!
Thanks for the ping.

I don't know what is referred to in #c4 by "requests are explicitly cancelled".  I see a call to WebContentsImpl::Stop from WebContentsImpl::*SavePage methods, but I thought that this would only stop navigations, not XHRs.

Anyway, I think it should be fine to not stop the pending requests (both for navigations and XHRs).  I don't really understand the benefit of stopping the navigations or other pending requests.  Even if we don't stop the navigations, the page might change while save is in progress (we don't stop javascript from executing).

FWIW, this code traces back to the initial commit:

552	void WebContents::SavePage(const std::wstring& main_file,
553	                           const std::wstring& dir_path,
554	                           SavePackage::SavePackageType save_type) {
555	  // Stop the page from navigating.
556	  Stop();
I agree to lukasza that it does not make sense to stop the requests. So I think the Stop() call can be removed.
Owner: shaktisahu@chromium.org
Status: Assigned (was: Untriaged)

Sign in to add a comment