Client cached packages - Massive Storage consumption

Hi,
I faced that f-droid uses 1.7 GB of storage. After deleting it and using it for a day again. I am at a more reasonable 157MB. Is this big size expected behavior? I do not use any extra repos or something like that. I only configure the theme of the app, so deleting the data regulary is no big hassle for me.

2 Likes

it keeps the apps you download cached, it should automatically clear itself after some time period

1 Like

In theory, but… @funny0facer try to disable battery optimisations for F-Droid, setup a low “keep packages” (albeit the default should be ok), keep an eye on it

1 Like

when I read “cached” I would expect it in the “cache” size and not in the user data.
I changed battery optimisation now. i will keep an eye on it.

1 Like

It’s “complicated” it gets copied there for install

and

My theory is that F-Droid gets killed (hence me asking about excluding from battery opts) and does not get a chance to cleanup

3 Likes

This issue is a never ending headache
F-Droid client should store apps in cache storage and not in user data
This is why any sane person will just use third party clients.

2 Likes

To disable the battery optimization for F-Droid did work. The userdata did get cleared.
So thanks for pointing me there :+1:

4 Likes

Which of these issues is best place tracking a fix? I can understand copying it there temporarily for install, but not deleting that immediately upon detecting the app is up-to-date, while keeping the original cached copy as long as directed by preference or when user chooses to clear app cache. :confounded:

I guess they might get fixed both but no one is working on that afaik

1 Like

On many phones it’s impossible to completely disable the battery optimizations by the way, and on phones with little ram apps will get killed frequently in any case.

I have to clean the app’s storage at least every few weeks, and it’s a pain because you have to then set again the options and especially the repositories.

So while this issue gets completely solved (although it seems it would be enough to store all the apks etc in the cache…) an ability to export and reimport the settings and ideally a command to manually clean all the junk would be very helpful.

1 Like

That request is in limbo for years.…

1 Like

As per other threads, apk of apps downloaded from fdroid are stored in the root directory. Why does it save the apk in the root directory and not in the main directory where a user can view it if the phone is not rooted? What is the point of saving each downloaded apps apk in phone and is there a way to disable this?

1 Like

There is a way, enable packages cleaning in Settings. You setup that to 1h and it did not work?

Try the latest 1.19.0, clean app cache, test for a bit…

1 Like

Thanks. But why is it saving apks in the first place in phone and that too why in root directory? What is the need for that once an app is installed? Is there a way to disable it from saving the apks?

1 Like

It needs the APK to be installed, then, as the setting says… it will clean up

You want them deleted? There are others that want to keep them. Each with their own prefs :person_shrugging:

1 Like

Else it would need “dangerous permissions” and others will start opening threads about “why does F-Droid need to read my pictures!!!11” :slight_smile:

Also, it’s not “root directory” but “private app internal space” /data/data/org.fdroid.fdroid/... right?

1 Like

But it requires root to access them, right? Still not able to understand why not just install the app, why download and save the apk and fill up more space?

So, if one selected 1 hour then is it for sure that the apk will get cleaned in an hour? This is assuming that the user doesn’t has root so no way to make sure if it. Also if the cache of fdroid is cleared then will it lead to deletion of the apk?

1 Like

an app does not need special access rights to access its own private app storage space.

Other apps can’t access that space, no, you via another app like a file manager can’t

it needs space to save the file before installing, and yes there might be an issue with duplicate copies during install, known issue

In theory, bugs aside, yes… this thread is about the issue of “not cleaning up in time” yes

Scroll above to see the Gitlab issues that the team keeps track of

Thanks. Last questions, there is no way to stop fdroid from saving the apks before installing them?
Let’s say there are bugs and duplicate copies are there. Like you have mentioned that it stores then in its own private space, say fdroid is uninstalled then will ask the saved apks get deleted or will the bug prevent them from getting deleted?
If one clears the cache of fdroid from the app settings then can the bugs prevent the save apks from getting deleted?