I am using uri (SAF) to save files.
1) FAT32 has 4GB limitation for a single file. When we download a 4.6GB file to FAT32 memory card, fetch creates 4GB file & starting download. When progress reaches 4GB, download failed with 'UNKNOWN_IO_ERROR'
2) Internal storage (Linux File System) of android device has 2GB free space. We start a 3GB file download. Fetch creates 2GB file & starts downloading. When progress reaches 2GB download failed with 'UNKNOWN_IO_ERROR'
This is serious problem for users. Huge amount of data will be wasted, if these scenarios are not properly handled.
Fetch should try to pre-allocate the file, if the file cannot be allocated for required download size, then it should show 'FILE_ALLOCATION_ERROR'.
Waiting for your reply...
@jpvs0101 looking into this.
fixed. will be in next release
Very cool, what is the new behaviour?
@jpvs0101 new version of fetch is now available with this new feature. See readme and changelog.
On enqueue Fetch will try to pre allocate the file on local storage. If it fails an error is returned FILE_ALLOCATION_FAILED. This feature can be turned off in the fetch configuration. It is on by default.
Working! Thanks!