Closed uttiya10 closed 4 years ago
This is not a bug. The download system is designed in such a way that no additional downloading tasks will be initiated when the app is in the background. That's why we recommend people to leave the app open when they've queued multiple downloads so that the app can take care of the queued episodes at its discretion.
The reason why the download system is like this is that the URL loading system limits the ability for apps to schedule downloads consecutively. See the Use Background Sessions Efficiently section of the Downloading Files in the Background if you want all the details. But, in short, Apple delays the downloading tasks that are scheduled right after a download completion call, which means our download system won't work reliably if we try to schedule downloads in such ways.
Now I haven't done much research about how the system calculates the delay for consecutively scheduled tasks. It may not be as big of a deal as I thought. If you want to do some experiments, then, by all means, go ahead. I'd be interested to see the results as well.
Describe the bug NineAnimator only downloads 2 episodes at a time, and queues any other episodes. When the app is in the background, the queued episodes will never start downloading.
To Reproduce Replace this with the steps to reproduce the behavior:
Expected behavior All episodes have finished downloading
Actual behavior First two episodes finish downloading, while the queued episodes will only start upon app entering foreground.
Device:
Additional context Mustard is disgusting.