Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I need a way to add/control the number attemps when downloading a source. #109

Open
tuqueque opened this issue Oct 19, 2022 · 1 comment

Comments

@tuqueque
Copy link

Hello, first of all, thank you for this awesome tool! I've been using it for a couple of years now and it works amazingly!

But there's a problem that over time has become unbearable, and is that over the years I have built a massive list of host sources (187 sources so far) and sometimes one... or a few of those sources becomes temporarily unavailable or more commonly, their connection becomes slow or intermittent; which constantly makes hblock close with an error and I have to run it again, and again... and again until either succeeds or I give up after an hour wanting to throw the computer out the window!

Is there a way of making hblock automatically repeat several times (with a parameter controlled by the user) before giving up and instead of just exit with an error, just move to the next source in the list?

I REALLY hope this is possible to implement, 'cause this is becoming unbearable as I make my sources list more extensive.

Thanks in advance!

@hectorm
Copy link
Owner

hectorm commented Oct 23, 2022

With the -c (--continue) option you can ignore download errors, but currently there is no retry or timeout option implemented.

I think it's a good idea to offer more control over downloads, as long as curl, wget and fetch support the feature it's not hard to add one more option.

In the meantime you can manually modify the fetchUrl function to suit your needs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants