The download should fail.
The notification displays the download to be complete.
This issue is really strange. In Sample Browser inside of Android Components, the way I implemented this, an IO exception is thrown when the internet cuts out. However, for some reason, inside of Fenix, that IO exception is either never thrown or is being caught by some universal catch somewhere?
@BranescuMihai if you're digging into this more, it's going to be in this section of the code:
Really strange that this is working as expected in Sample Browser but not inside of Fenix 馃槙 they're both using the same download service.
@sblatz yep, I was looking into that method, but thanks for the idea with the Sample browser, will check that out
Thanks for investigating this, @BranescuMihai! Sounds like we need a GV/AC patch to fix this.
This should now be partially fixed. Files that have a download size will now fail when the wifi is cut off. The file does not have a content length, we're still waiting on that GV fix.
QA could you verify that this is partially fixed and I'll keep this open track the GV one?
@sblatz
This still has some issues:
@sv-ohorvath thanks for catching those 馃槃
https://github.com/mozilla-mobile/fenix/pull/6645 Should address point 1
https://github.com/mozilla-mobile/android-components/pull/5076 Should address point 2
Verified as fixed on Nightly 11/19.
To be clear, the GV bug still stands which means that this will still have incorrect behavior when files do NOT have a file size. https://github.com/mozilla-mobile/android-components/issues/4999 Will track that :)
Most helpful comment
@sv-ohorvath thanks for catching those 馃槃
https://github.com/mozilla-mobile/fenix/pull/6645 Should address point 1
https://github.com/mozilla-mobile/android-components/pull/5076 Should address point 2