lutris / agora

Public discussion space for the community
11 stars 0 forks source link

[Feature Request] Retry Function for Cancelled Downloads during Install. #65

Closed odysseywestra closed 3 years ago

odysseywestra commented 3 years ago

One thing I noticed while install testing Cyberpunk 2077, and Horizon Zero Dawn during the install from the GoG source is that if a download is cancelled there is no way to restart the said download. Plus randomly, a part will just not downloads and just hang. I know in the latest commits there a limit of 5 parallel downloads which for the most part did get rid of the problems of them just stopping. Though if it did happen again or a user had to cancel that part of the download to improve the speed of the other downloads, having the ability the restart that download would greatly help.

odysseywestra commented 3 years ago

Example of failed download in Terminal with lutirs -d. I've shorten the urls to keep it clean:

DEBUG    2020-12-22 07:33:34,293 [downloader.start:57]:Starting download of:
 https://content-system.gog.com/products/...
INFO     2020-12-22 07:33:34,297 [cache.save_to_cache:28]:File is already cached in /run/media/albert/Steam_Backup/GOG Backups/Cyberpunk_2077/00-Game-Files/Full-1.05/cyberpunk-2077/gog, skipping
INFO     2020-12-22 07:33:45,600 [downloader.async_download:119]:https://content-system.gog.com/... returned a 504 error
ERROR    2020-12-22 07:33:45,601 [jobs.target:36]:Error while completing task <bound method Downloader.async_download of <lutris.util.downloader.Downloader object at 0x7f72c7c4f250>>: 504 Server Error: Gateway Time-out for url: https://content-system.gog.com/products/...
  File "/usr/lib/python3.9/site-packages/lutris/util/jobs.py", line 34, in target
    result = self.function(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/lutris/util/downloader.py", line 120, in async_download
    response.raise_for_status()
  File "/usr/lib/python3.9/site-packages/requests/models.py", line 943, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
ERROR    2020-12-22 07:33:45,604 [downloader.download_cb:88]:Download failed: 504 Server Error: Gateway Time-out for url: https://content-system.gog.com/products/...
Traceback (most recent call last):
  File "/usr/lib/python3.9/site-packages/lutris/gui/widgets/download_progress.py", line 95, in _progress
    self._set_text(self.downloader.error[:80])
TypeError: 'HTTPError' object is not subscriptable
odysseywestra commented 3 years ago

Closing in favor of: https://github.com/lutris/lutris/issues/3364