Comments (21)
Hello @Gitoffthelawn.
The app no longer reports the total amount of cache cleaned because of multiple reasons. First, the number did not use to be accurate, which renders it useless. Second, due to an optimization that allows you to skip scanning before cleaning, the number may not even be available.
Does the actual cleaning work for you ? If not, please, write your device, Android version, ROM and of course, post the logcat output.
from android-cache-cleaner.
@Kuci Thanks for the details regarding the total amount cleaned.
I will triple-check, but I'm quite sure that nothing is being cleaned.
Since v2.2.0 was just released, let's give it a few days to see if others are also having the issue. The test was conducted on a stock Android 4.4.2 (SDK 19) LG ROM.
from android-cache-cleaner.
@Gitoffthelawn Why are you quite sure that nothing is being cleaned ? Do you have any numbers ? Any cases of failure ?
from android-cache-cleaner.
@Kuci When I would run the previous version, it would seem to work. I would then run it again, and the sizes of all the caches would be zero within the app, showing that it was most likely working correctly. To test it, I would go into the stock Android apps manager, and it would show all the caches at zero (except for ones for active processes that quickly get recreated).
When I run the current version, it seems to work as well. No errors. But when I run it again, it shows most of the caches have not been deleted. Going in to the stock Android apps manager confirms this observation.
The first few times I tested the latest version, it did not appear to delete any caches at all. I've had a moment to try it again, and it appears it is deleting some, but not all, caches. Is there a new limit to not delete caches under a certain size?
I was thinking about your comment regarding the size of the caches cleared not being accurate within the app... from what I can see, the cache sizes reported in the app match those reported by the stock Android apps manager. Is it that those values are correct, but the amount cleared was not? If so, why the discrepancy?
from android-cache-cleaner.
@Gitoffthelawn The only thing we can do about internal cache is to tell Android to free some space, but can not predict how much space will actually be freed.
This line might be buggy on your ROM. I will try to work it around tomorrow and provide you with a branch containing potential fix, so that you could test it out.
from android-cache-cleaner.
@Kuci No rush at all. :-) I'm busier than I prefer and not sure when I will have time for testing.
Just to clarify and to make sure I'm not misunderstanding, the function of this app is to only clean the internal app caches within the limits of Android (nothing more and nothing less), correct?
In other words, it should be the exact same as pressing Clear Cache for each app in the stock Android apps manager, right?
IIRC, the previous version of this app would reduce cache sizes of all apps to zero. Caches for active processes quickly get recreated, but those are a minority. This new version does not seem to touch most (perhaps any) caches under 100KB and sometimes misses larger ones. I suppose I could have just thought the previous version was working, but I'm pretty sure I double-checked the results via the stock Android apps manager. I was not keeping a written record, however.
I gave Power Clean and CCleaner a try to see how they compare to this project. Power Clean finds and deletes app caches of all sizes. CCleaner seems to find and delete app caches over a certain threshold, perhaps 32KB (the smallest it found was 44KB). I don't know why CCleaner ignores smaller caches.
Here is a quick comparison of the app caches they found in one test:
- Power Clean: 20.4 MB
- Cache Cleaner: 20 MB
- CCleaner: 16.11 MB
from android-cache-cleaner.
@Gitoffthelawn No, it does not do the exact same thing that Clear Cache button in Settings does. Settings app uses API that allows it to immediately delete a cache. We can not use the same API because a permission required to use that API is not available to 3rd party apps in any version of Android. Cache Cleaner uses another API which tells Android how much space in internal storage we would like to be freed and it tries to free as much as we ask for. It is not as reliable as the button in Settings app, yet I find it very reliable on all the devices I have been testing Cache Cleaner on.
Therefore, it is not up to Cache Cleaner what is being cleared, it is up to Android and we can do pretty much nothing about it.
from android-cache-cleaner.
@Kuci That's a fantastic (and very well written) explanation. Thank you!!!
What happens if you just always tell the API that you want a large value to be freed (64GB, for example)?
I also found Cache Cleaner to be very reliable. When I started using it, it seemed to be just as effective as pressing the Clear Cache button in the stock Android apps manager (although much faster when there are hundreds of apps!).
Any ideas what Power Clean and CCleaner are doing? I will have to double-check, but I think they both list the cache sizes for specific apps. That makes me think they are somehow clearing specific app caches (or at least making it look like they are). I have a hunch (and it's just a guess) that CCleaner uses the same technique as Cache Cleaner, but Power Clean might be using another technique.
from android-cache-cleaner.
@Gitoffthelawn Then Android will try to free 64GB of internal storage. Cache Cleaner tells Android to free as much as is the size of data partition. In other words, data partition on my Nexus 5 is 12.6 GiB, so Cache Cleaner tells Android to free 12.6 GiB of internal storage.
Both Power Clean and CCleaner use the same permission that Cache Cleaner uses, so both of them must be using the same API that we do.
from android-cache-cleaner.
@Gitoffthelawn I have created issue-30
branch. Please, try it yourself if you can and report the results.
from android-cache-cleaner.
@Kuci Thanks. It's on my list. Will be quite some time, but it's in the queue.
I have a few more questions / ideas, and will hopefully have time to post again soon.
In the meantime, quick question: Can you think of any changes in the latest version that would cause this issue (besides the one for the test build)?
from android-cache-cleaner.
@Gitoffthelawn e54a76c is the only commit between v2.1.6
and v2.2.0
in which I have made changes to the code related to internal cache cleaning, so no.
from android-cache-cleaner.
@Gitoffthelawn This issue has been opened for over 2 weeks now, are you having troubles with testing ? Do you want me to compile it for you ?
from android-cache-cleaner.
My apologies... I've been overbooked. I've also been thinking about an effective methodology to test it and compare it's results to other tools. Do you have any ideas?
If you can compile it, that would be great.
from android-cache-cleaner.
Here it is, I have compiled it for you. Just replace .txt
with .apk
and install it on your device. Let me know about the results.
from android-cache-cleaner.
@Gitoffthelawn It has been a week since I posted the APK, what is the result of testing ?
from android-cache-cleaner.
@Kuci What do you think is an effective methodology to test it?
from android-cache-cleaner.
@Kuci I'll have a test system available for about 20 more minutes if you have a good idea on how to test it effectively.
from android-cache-cleaner.
@Kuci I completed the testing. Here are the results.
Test operating system: Android KitKat v4.4.2
Step 1: Opened Cache Cleaner v2.2.0 (public release)
Used: 3.1GB
Cache: 102MB
Free: 743MB
Step 2: Cleaned cache with Cache Cleaner v2.2.0
Step 3: Rescan
Used: 3.1MB
Cache: 4.6MB
Free: 838MB
Step 4: Cleaned cache with Cache Cleaner v2.2.0
Step 5: Rescan
Used: 3.1MB
Cache: 4.6MB
Free: 838MB
Step 6: Cleaned cache with Cache Cleaner v2.2.0
Step 7: Rescan
Used: 3.1MB
Cache: 4.6MB
Free: 838MB
Noticed that many caches still exist, with maximum cache sizes of 76KB
Step 8: Uninstalled Cache Cleaner v2.2.0
Step 9: Installed Cache Cleaner v2.2.0.9-g5963eee (test version)
Step 10: Opened Cache Cleaner v2.2.0.9-g5963eee
Used: 3.1GB
Cache: 4.8MB
Free: 836MB
Step 11: Cleaned cache with Cache Cleaner v2.2.0.9-g5963eee
Step 12: Rescan
Used: 3.1GB
Cache: 4.6MB
Free: 836MB
Noticed that many caches still exist, with maximum cache sizes of 76KB (appear to be same apps as in Step 7)
Step 13: Cleaned cache with Cache Cleaner v2.2.0.9-g5963eee
Step 14: Rescan
Used: 3.1GB
Cache: 4.6MB
Free: 836MB
Noticed that many caches still exist, with maximum cache sizes of 76KB (appear to be same apps as in Step 7)
Step 15: Cleaned cache with Cache Cleaner v2.2.0.9-g5963eee
Step 16: Rescan
Used: 3.1GB
Cache: 4.6MB
Free: 836MB
Noticed that many caches still exist, with maximum cache sizes of 76KB (appear to be same apps as in Step 7)
Step 17: Opened CCleaner v1.11.43. It reported 14.08MB can be cleaned, but there was no specific option for system cache, so did not clean.
Step 18. Opened PowerClean v2.7.10. It reported System Cache 4.75MB
Step 19. Clean System Cache (and only System Cache) using PowerClean
Step 20: Opened Cache Cleaner v2.2.0.9-g5963eee
Used: 3.1GB
Cache: 4.6MB
Free: 835MB
Step 21: Cleaned cache with Cache Cleaner v2.2.0.9-g5963eee
Step 22: Rescan
Used: 3.1GB
Cache: 4.6MB
Free: 835MB
Step 23: In Cache Cleaner v2.2.0.9-g5963eee, clicked on first 3 apps with 76KB caches (each), and manually cleared them using Android UI
Step 24: Rescan
Used: 3.1GB
Cache: 4.4MB
Free: 835MB
Step 25: In Cache Cleaner v2.2.0.9-g5963eee, clicked on next 7 apps with 76KB caches (each), and manually cleared them using stock Android UI
Used: 3.1GB
Cache: 3.9MB
Free: 835MB
Conclusion: Cache Cleaner v2.2.0.9-g5963eee is no more effective than v2.2.0. Stock Android App Manager can clean caches that Cache Cleaner v2.2.0.9-g5963eee and v2.2.0 cannot. Although it is more effective than Cache Cleaner, it is significantly more tedious and time consuming to use the Android App Manager.
from android-cache-cleaner.
@Gitoffthelawn I am sorry for not replying, I was not on the internet.
Your testing methodology looks good and so do the results. v2.2.0
seems to be working properly because there is always some insignificant cache size, which is somehow locked by Android and we can do pretty much nothing about it.
Thank you for reporting and testing.
from android-cache-cleaner.
@Kuci You're welcome. Glad to help.
from android-cache-cleaner.
Related Issues (20)
- [feature-request] option for total amount of cache cleaned HOT 2
- Schedule interval for cleaning HOT 2
- Cache cleaner not clearing datas in marshmallow HOT 7
- FR: List of exclusion HOT 4
- [FR] sort by full size HOT 3
- One of the setGitDir or setWorkTree must be called HOT 1
- Android 6.0 issue and quick solution HOT 2
- Translating HOT 1
- Broken link on page https://f-droid.org/wiki/page/com.frozendevs.cache.cleaner#2.2.0 HOT 3
- Impossible to install any version of Cache Cleaner on my Android 4.3 Hisense mobile HOT 1
- Add a confirm popup before cleaning HOT 5
- Easy accessible button to start Android's new cache manager HOT 7
- Automatic Clean every few hours HOT 1
- Copyright violation HOT 4
- getPackageSizeInfoAsUser() is not working in Android O HOT 11
- error git
- Memory Leak
- Updated de (German) translation
- Supporting Android Marshmallow and above.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from android-cache-cleaner.