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

Add support for resuming partial downloads #3

Open
TheDcoder opened this issue Aug 22, 2021 · 3 comments
Open

Add support for resuming partial downloads #3

TheDcoder opened this issue Aug 22, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@TheDcoder
Copy link

I noticed that gogcli currently starts the download from scratch if I interrupt it, it would be nice if there was an option to resume partially downloaded files.

I tested this using the gog-api download-url-path command.

Perhaps an additional command to verify the checksum of an already downloaded file would be nice to have too! 😁

@Magnitus-
Copy link
Owner

Magnitus- commented Aug 30, 2021

There is the following command though it lacks the granularity you are seeking here for verification:

gogcli storage validate

Note that complementary to the above command, the following command will generate actions in your storage which you can resume to fix any divergence between your manifest and your stored files (including checkum values):

gogcli storage repair

Otherwise, for resuming downloads, its complicated right now. GOG provides endpoints for partial downloads, though for at least one game, I noticed it was broken (the xml data the api returns to parse the partial downloads metadata is literally malformed). Maybe its better on newer api endpoints though.

Also, I don't think I'd want to get into managing the logistics where some games are downloaded via partial file downloads and others are downloaded via complete file downloads (because the checksums are computed differently, you can't just mix them, you'd have to keep an account of how each file was downloaded).

Anyways, I won't say never, but realistically, partial downloads may take some time to support. Thankfully, for Windows installers at least, the installers are already broken down across several files by GOG and they tend not to have a Linux version for the biggest AAA games.

More fine-grained downloaded files validation would be more feasible to implement in the not so distant future though.

@TheDcoder
Copy link
Author

Thanks for the info on validation.

Otherwise, for resuming downloads, its complicated right now. GOG provides endpoints for partial downloads, though for at least one game, I noticed it was broken (the xml data the api returns to parse the partial downloads metadata is literally malformed). Maybe its better on newer api endpoints though.

If I am understanding correctly, there are two API endpoints for downloading game files? I am assuming the "newer" endpoint is what GOG Galaxy uses, as it can pause and resume downloads. Hope support for this comes one day 😄

@Magnitus- Magnitus- added the enhancement New feature or request label Oct 13, 2021
@Magnitus-
Copy link
Owner

If I am understanding correctly, there are two API endpoints for downloading game files? I am assuming the "newer" endpoint is what GOG Galaxy uses, as it can pause and resume downloads. Hope support for this comes one day smile

I believe that it may actually be a legacy feature that the now deprecated GOG Downloaded used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants