Dongw1126 / Auto-Resume-Downloads

Auto Download Resume Chrome extension
https://chrome.google.com/webstore/detail/auto-resume-downloads/pifbhionjpacnpjoaomhdpbekkdphdgd
MIT License
40 stars 4 forks source link

chrome.downloads.resume stuck after a certain number of resume failures #7

Open Dongw1126 opened 3 years ago

Dongw1126 commented 3 years ago

Currently, the maximum value of Chrome's automatic restart attempts is set to 5 times, so if the restart fails more than 5 times, the operation of the downloaded item will stop.

chromium source code

Since the number of attempts is initialized after a user gesture occurs, API or code to solve this programmatically is needed.

nyhtml commented 3 years ago

Hi @Dongw1126 What OS/platform did this affect? Would the Edge browser be affected as well? Just curious since I have a Hackintosh system and use both Edge and Chrome.

By the way, thanks. I have files on The Internet Archive and would get disconnected. After installing your extension, it downloaded with ease in the background.

Dongw1126 commented 3 years ago

Hi @nyhtml This bug occurs when the server does not respond to the download resume request more than 5 times. I tested in Windows NT 10.0; Win64, Chrome/94.0.4606.71, but it probably affects all Chromium-based web browsers regardless of OS. Thanks.

RobT2012 commented 2 years ago

The same issue affects the Linux version of chrome browser (tested the official version from Google), it works for a while then stops.

andrewcupper commented 1 year ago

A hacky work-around (works on version 115.0.5790.114 (Official Build) (arm64)) is to add a pause and resume after each successful resume (ie. at https://github.com/Dongw1126/Auto-Resume-Downloads/blob/main/src/background.js#L115). The pause causes a reset of the auto_resume_count on the subsequent resume: see https://source.chromium.org/chromium/chromium/src/+/main:components/download/internal/common/download_item_impl.cc;l=640

bulletng commented 1 year ago

Any update with this? I'm not quite sure how to add the modifications above. Could someone help?

RobT2012 commented 1 year ago

I gave up and used a download manager extension, this one is working really well for me. It's a lot better than the built in version, so even if the problem gets fixed I'll never go back anyway. https://github.com/persepolisdm/persepolis

There are other download managers to choose from, so if it doesn't work out you can always try another one.

Dongw1126 commented 1 year ago

A hacky work-around (works on version 115.0.5790.114 (Official Build) (arm64)) is to add a pause and resume after each successful resume (ie. at https://github.com/Dongw1126/Auto-Resume-Downloads/blob/main/src/background.js#L115). The pause causes a reset of the auto_resume_count on the subsequent resume: see https://source.chromium.org/chromium/chromium/src/+/main:components/download/internal/common/download_item_impl.cc;l=640

@andrewcupper Thanks for your advice.
I will try to use it in resolving the issue.
I'll let you know when it's done.

pto2k commented 11 months ago

I hope this will be resolved soon. I'd prefer using the internal downloader of Chrome to an external program.

vaclavmuller commented 9 months ago

I'm downloading a 41GB file from google drive and it keeps crashing. That's why I installed this plugin. Unfortunately, I have the same problem with the limit and have to reset it manually.

tangre commented 6 months ago

Any word on this being resolved? This would be perfect for me if you could set it to retry infinitely until it grabs again. Seems a little bizarre that we're limited to 5 retries then we absolutely must retry manually from there.

RobT2012 commented 6 months ago

There's been several updates of Chrome, but I've not tried it in a while because my solution to use a download manager, has been working well for me. It's not perfect, but even without the failed downloads, it's still a lot better than Chrome's built in system, and it can be used with any browser which is another bonus as I use FF sometimes.