New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 643731 link

Starred by 4 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Dec 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug



Sign in to add a comment

Download link menu item fetches raw html that is saved to downloads home

Project Member Reported by fgor...@chromium.org, Sep 2 2016

Issue description

Version: 54.0.2840.0 (and ToT)
OS: Android

What steps will reproduce the problem?
(1) open any page
(2) Long press a link (to another page) and select Download link
(3) Wait for notification that link was downloaded
(4) Go to Download manager and try to open the saved link

What is the expected output?
A richer version of the page is saved.

What do you see instead?
html page only, which cannot even be opened by chrome
(Android html viewer and docs are the 2 options available)


This is not necessarily a bug, as it might be considered a feature request. We currently tests async loading with an extra button, but perhaps knowing there is an html at the other end using Background loader instead of download manager would be more appropriate for such links.

 
Cc: asanka@chromium.org
Owner: asanka@chromium.org
When download starts and fetches headers - it might discover that the resource behind the link is text/html. In that case, Download manager may transfer the 'download' to Offline Pages backend.
This seems like a design is needed between Downloads and Offline. Assigning to asanka@ since this starts form download side.
Cc: -asanka@chromium.org
Labels: M-55 OS-Android
Status: Assigned (was: Untriaged)
(triage) We'd like this to be addressed in M55

asanka@, if you need any help from the offline pages folks please ping us or this bug.

Comment 3 by asanka@chromium.org, Sep 23 2016

Labels: -M-55

Comment 4 by asanka@chromium.org, Sep 23 2016

Just to be clear, this is not going in for M55.
Cc: dewittj@chromium.org
 Issue 663299  has been merged into this issue.
Cc: vitaliii@chromium.org

Comment 7 by dim...@chromium.org, Nov 15 2016

Owner: dim...@chromium.org

Comment 8 by talo@chromium.org, Nov 15 2016

Labels: M-57

Comment 9 by dim...@chromium.org, Nov 23 2016

Issue 668233 has been merged into this issue.
Status: Started (was: Assigned)
Project Member

Comment 11 by bugdroid1@chromium.org, Dec 20 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/4f6b28049376a0e309fda4cbeb6e4d7aac98965c

commit 4f6b28049376a0e309fda4cbeb6e4d7aac98965c
Author: dimich <dimich@chromium.org>
Date: Tue Dec 20 00:18:33 2016

[Android Downloads] Long-press menu item "Download Link" should delegate job to OfflinePages backend.
This patch interrupts the download and hands it off to the OfflinePage backend once the mime type of the download is detected and it is text/html.
Other downloads not affected.

BUG= 643731 

Review-Url: https://codereview.chromium.org/2528483003
Cr-Commit-Position: refs/heads/master@{#439630}

[modify] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/browser/BUILD.gn
[add] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/browser/android/offline_pages/downloads/resource_throttle.cc
[add] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/browser/android/offline_pages/downloads/resource_throttle.h
[add] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/browser/android/offline_pages/downloads/resource_throttle_unittest.cc
[modify] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/browser/android/offline_pages/offline_page_utils.cc
[modify] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/browser/android/offline_pages/offline_page_utils.h
[modify] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/browser/loader/chrome_resource_dispatcher_host_delegate.cc
[modify] https://crrev.com/4f6b28049376a0e309fda4cbeb6e4d7aac98965c/chrome/test/BUILD.gn

Status: Fixed (was: Started)

Sign in to add a comment