Fetch icon indicating copy to clipboard operation
Fetch copied to clipboard

Skipping download because it already exists in the Fetch database

Open pvenrod opened this issue 11 months ago • 2 comments
trafficstars

Hi!

My application is skipping a download because it already exists in the Fetch database. This is happening because, by mistake, I am using the same filename for all downloads.

My current integration is quite simple:

val request = Request(result.url, Uri.fromFile(File(file, FILE_NAME))).apply {
     priority = Priority.HIGH
     networkType = NetworkType.ALL
     addHeader(FIXED_URL_HEADER, "true") // This is internal stuff from my app
}

It doens't matter which file url I use, Fetch just check its database before doing any other stuff and, if the internal filename is the same, it skips the download and returns the old file. So my app is not even requesting the file to the server, it is just skipping the download.

I have this problem in production and I don't know how to solve it, as there are a lot of affected users not being able to download the file.

Is there any workaround I can do for those users in production that are already affected? At this moment is not possible to update the code or launch any app update.

Will fetch automatically clean its database after X period? Or is there any workaround to let Fetch think that the new file is not the same as the one that it has in the database, even if the filename is the same?

I have access to the external file and can change its content and url, just in case it helps.

pvenrod avatar Dec 19 '24 15:12 pvenrod

Having absolutely the same problem. Also, I'm not sure how to fix this. Did you find a solution?

DanielStankovic avatar Mar 07 '25 10:03 DanielStankovic

@DanielStankovic not yet :(

pvenrod avatar Mar 20 '25 07:03 pvenrod