Open requests are canceled when trying to saving the page
Reported by
denis.tr...@unblu.com,
Sep 30 2016
|
||||||
Issue descriptionUserAgent: 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
,
Sep 30 2016
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.
,
Oct 12 2016
This is SaveAs issue on WIndows, changing component.
,
Dec 8 2016
Pending requests are explicitly cancelled prior to starting a Save As operation. lukasza: Do you know if that requirement can be relaxed?
,
Dec 11 2017
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
,
Jan 18 2018
lukasza@ just checking in on #4. Thanks!
,
Jan 18 2018
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();
,
Jan 19 2018
I agree to lukasza that it does not make sense to stop the requests. So I think the Stop() call can be removed.
,
Feb 1 2018
|
||||||
►
Sign in to add a comment |
||||||
Comment 1 by woxxom@gmail.com
, Sep 30 2016