Giter Site home page Giter Site logo

Comments (9)

Morasiu avatar Morasiu commented on May 8, 2024 1

I have a problem with all my files resuming. That file was just an example to test it correctly. I think it happens in 100% of cases.

I've installed IDM and tried downloading this file. It downloaded without any problems and I could easily stop and resume download a few times.

But...

That there is still a problem with the library creating corrupted files with more MB than the original file.

from downloader.

Morasiu avatar Morasiu commented on May 8, 2024 1

Sure. I'm not in hurry. Take your time to improve that already awesome library! ❤️

from downloader.

Morasiu avatar Morasiu commented on May 8, 2024 1

Resuming now works correctly. Thanks ❤️

from downloader.

bezzad avatar bezzad commented on May 8, 2024

Hi @Morasiu
I can't download from your URL http://ipv4.download.thinkbroadband.com/50MB.zip:
Screenshot 2021-03-30 220342

Does this always happen?
Do other files have this problem in downloading?

I asked this because some servers do not have the ability to resume downloading. That's why I checked with the IDM and it also couldn't download. There is another case, that I live in an area that does not have quality internet and may not be able to download.
If you can, download your file with IDM and stop and resume it to make sure this server has no case. Thank you

from downloader.

bezzad avatar bezzad commented on May 8, 2024

I tested your URL with a VPN and that's correct. I ran this scenario several times in my program and there was no problem and even unit tests on different servers were not a problem. I think this problem can only occur when the package file is not saved at the right time or changes after the temp files after saved. The only right time to save the package file is after the download is cancelled. Therefore, if the values stored in the files do not match the package values, the downloader will start downloading from the begging.
Now, make sure that the package is saved right after the download is cancelled, which is the best place to make sure the inside is the DownloadFileCompleted events.

from downloader.

Morasiu avatar Morasiu commented on May 8, 2024

So... I'm writing an application that can download large files over not so stable connections. Can I use that feature of the library to resume downloading after someone computer shutdown unexpectedly or after their lost connection to the internet (I guess then event DownloadFileCompleted with some errors is fired?

Also, I'm not sure if I understand correctly. Can I save the package at any moment or not? If not how can I be sure, when to save the package? I'm currently saving a package every 10s of download using the DownloadProgress event.

from downloader.

Morasiu avatar Morasiu commented on May 8, 2024

I think it's still a bug if DonwloaderService is appending data over total bytes in the downloaded temp file.

from downloader.

bezzad avatar bezzad commented on May 8, 2024

Yes, this is a bug in appending data to the same temp files after restarting the download. But if you store the Package file after the cancelled event this problem not occur.
Let me find a way to save the package file whenever you want and resume whenever you want. Because for this scenario, only this method can work. Give me some time to implement this feature.

from downloader.

bezzad avatar bezzad commented on May 8, 2024

@Morasiu Please test the new version 2.2.8 for this problem. Thanks

from downloader.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.