Closed Bug 1977393 Opened 8 months ago Closed 8 months ago

[Downloads v2] Live download state does not update after killing the app

Categories

(Firefox for Android :: Downloads, defect)

All
Android
defect

Tracking

()

VERIFIED FIXED
143 Branch
Tracking Status
firefox143 --- verified

People

(Reporter: npoon, Assigned: titouan)

References

(Blocks 1 open bug)

Details

(Whiteboard: [fxdroid][group4])

Attachments

(2 files, 3 obsolete files)

Steps to reproduce

  1. Start a download
  2. Go to the downloads screen and pause the download
  3. Kill the app
  4. Reopen the app
  5. Enter the downloads screen
  6. Click on pause, play, and or cancel

Expected behavior

The download pauses, plays, or cancels, or it shouldn't get shown on the downloads screen anymore

Actual behavior

The download does not respond to any of the action buttons. The download item cannot be deleted from pressing delete:

Attachment #9500703 - Attachment description: Bug 1977393 - Part 1: Fix download control actions after killing fenix → Bug 1977393 - Part 1: Fix unresponsive download control actions after killing fenix

The current behavior of Fenix Release is: when Fenix is killed, then the download is cancelled and won't be visible on the Download screen after reopening Fenix.

Currently, in Nightly: if Fenix is killed before a Download completes, after reopening Fenix the download will still be visible, but in a broken state where the Resume/Pause/Delete/Restart buttons don't have any effect.

This is because the communication with the service currently doesn't allow those features to work.

This is the approach we are taking:

  1. Put a patch that reproduces the behavior of Release and cancels a non-completed Download when Fenix is killed
  2. File a new bug to keep a Download even when Fenix is killed, and give the ability for the user to interact with it (Resume/Pause/Delete/Restart). This bug depends on Bug 1949821, requiring a non-trivial rework on the Download Service.
Blocks: 1977835
See Also: → 1977835
Assignee: npoon → tthibaud

Comment on attachment 9500703 [details]
Bug 1977393 - Part 1: Fix unresponsive download control actions after killing fenix

Revision D257309 was moved to bug 1977912. Setting attachment 9500703 [details] to obsolete.

Attachment #9500703 - Attachment is obsolete: true

Comment on attachment 9500704 [details]
Bug 1977393 - Part 2: Refactor DownloadFragment.openFile and remove FileItem.Status.toDownloadStateStatus

Revision D257310 was moved to bug 1977912. Setting attachment 9500704 [details] to obsolete.

Attachment #9500704 - Attachment is obsolete: true
Pushed by tthibaud@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/a487aac3c6ad https://hg.mozilla.org/integration/autoland/rev/a4874f74c4f7 Cancel non-completed downloads when the Download Service is killed r=android-reviewers,giorga
Pushed by amarc@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/2bb7128e8c6a https://hg.mozilla.org/integration/autoland/rev/73304b4f70e7 Revert "Bug 1977393: Cancel non-completed downloads when the Download Service is killed r=android-reviewers,giorga" for causing Android build bustages @ AbstractFetchDownloadServiceTest

Backed out for causing Android build bustages @ AbstractFetchDownloadServiceTest

Flags: needinfo?(tthibaud)
Pushed by tthibaud@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/a35f949a1f5c https://hg.mozilla.org/integration/autoland/rev/66db2aa095b8 Cancel non-completed downloads when the Download Service is killed r=android-reviewers,giorga
Flags: needinfo?(tthibaud)
Pushed by nbeleuzu@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/2120ad03c3ac https://hg.mozilla.org/integration/autoland/rev/8431bd0bd3ec Revert "Bug 1977393: Cancel non-completed downloads when the Download Service is killed r=android-reviewers,giorga" for causing build bustages
Pushed by tthibaud@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/b4f09ff654b5 https://hg.mozilla.org/integration/autoland/rev/54f4ac86d32f Cancel non-completed downloads when the Download Service is killed r=android-reviewers,giorga https://github.com/mozilla-firefox/firefox/commit/951ed6b79d4c https://hg.mozilla.org/integration/autoland/rev/6457309ebbc3 Fix intermittent tests in AbstractFetchDownloadServiceTest r=android-reviewers,pollymce
Flags: needinfo?(tthibaud) → qe-verify+
Status: ASSIGNED → RESOLVED
Closed: 8 months ago
Resolution: --- → FIXED
Target Milestone: --- → 143 Branch
Duplicate of this bug: 1978912

Verified as fixed on the latest Firefox for Android Nightly 143.0a1 from 8/12.
Tested with Samsung Galaxy Tab S9 Ultra (Android 15), and an Oppo Find X3 Lite (Android 11).

Status: RESOLVED → VERIFIED
Flags: qe-verify+
Regressions: 1984318

A patch has been attached on this bug, which was already closed. Filing a separate bug will ensure better tracking. If this was not by mistake and further action is needed, please alert the appropriate party. (Or: if the patch doesn't change behavior -- e.g. landing a test case, or fixing a typo -- then feel free to disregard this message)

Comment on attachment 9508578 [details]
Bug 1977393 - Don't delete completed downloads when killing Fenix

Revision D262015 was moved to bug 1984318. Setting attachment 9508578 [details] to obsolete.

Attachment #9508578 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: