-
Notifications
You must be signed in to change notification settings - Fork 736
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Request: Fix for blank/grey thumbnails after running SystemCleaner - "Thumbnail Files" #2661
Comments
Some thoughts/brainstorming:
The downside here would be that we don't know which files were represented by the deleted thumbnail files. Forcing a rescan on the whole storage could lead to previously not added media items being added to the databases, e.g. be shown in the gallery. Theoretically it should update itself, at the latest after a reboot, but it doesn't always do that and I have not yet found out under which conditions it does and doesn't update.
So far the idea with the least downsides, though we all know that not many read disclaimers ;).
I was under the impression that this would be equal to clearing the data of the media storage app 🤔 . |
This will be interesting
Hmm sometimes Android has a more watchful eye for newly added files, so there isn't much of a concern of new files popping up in the gallery. Android will sense new files one way or another in the strangest of ways. It's existing files where it doesn't "care".
For updating itself after a reboot, it's only for new files. I don't know however if this problem we're talking about, happens to all people or not. For me it happened on every phone and on every ROM I had ever since Android 5. There also exist some discussions online about this problem, where nobody pin-pointed the problem, like this recent one: https://www.reddit.com/r/GooglePixel/comments/avs44p/thumbnails_folder_growing_large_can_i_delete_it/ehlov9s This problem also doesn't happen in apps not using the Android media scanner. For instance: Google Photos, Solid Explorer, OnePlus Gallery, always re-create thumbnails because they have their own indexing engine. However: Instagram, Facebook and most other social media apps, the "Documents" built-in app for selecting files in Android, etc. rely on the media scanner and are affected by this.
Yeah everybody clicks ok ok next ;) At least the downsides aren't huge if you decide to implement an accessibility service to automatically click that button for no-root users.
In that folder there is another file: internal.db. Inside of that file there are some pointers to other media files like system sounds and others. I will continue my research on this. If absolutely nothing happenes in all the cases I can test, then wiping data completely of Media Storage will be the best option. |
Today I had some time for more tests. I'm trying to see if just deleting /data/data/com.android.providers.media/databases/external.db has the same effect as wiping the entire data for Media Storage. It seems that I lose the custom ringtone/notification selection in either case. And in either case a reboot it's needed for indexing media properly; otherwise it will appear as missing/not show up. No playlists were lost in either case. Apart from internal.db (which I will attach internal.db.zip, it's interesting, it appears useless but who knows...), There are two more files in the other directory of the Media Storage data folder: I can say with 99% certainty that we just can delete the entire data of Media Storage. People will just lose the custom ringtone/notification and need a reboot. Would you want to build a file modification tool into SD Maid? I can search for the exact thing in /data/data/com.android.providers.media/databases/external.db that's preventing the app from "seeing" that ".thumbnails" has been deleted. Also I am not able to test whether a force rescan solves this issue easily. Can you, or anyone seeing this, force a media rescan after deleting ".thumbnails"? Thank you. |
Hm for something that happens as part of regular intervals, requiring and potentially doing an automatic reboot is a HUGE impact on user convenience. "Just ringtones" will be enough for my inbox to fill with angry emails ;).
Depends on how much work it is. My concern would be that this will likely not be a "one solution fits all" thing, but rather something that requires different modifications depending on app version, Android version and probably also device OEM... 😲 Some more random thoughts: Would restarting/killing the media provider app, instead of rebooting also fix the issue? Does reinserting the sdcard have an effect? That's something we could potentially fake. |
What should the feature do?
It's a known issue of Android where if you delete the .thumbnails folder in sdcard/DCIM, the system will not longer re-create thumbnails for existing media, in apps using it's default media scanner (the "Media Storage" APK).
When/How would you use it?
After running SystemCleaner - "Thumbnail Files"
How would you implement it?
There are a few ways to implement this, as the developer explained to me in an email (facing the same issue) and I formulated here a few choices, since I would really want to see this brought officially in SD Maid for users not aware of this Android problem:
/data/data/com.android.providers.media/databases/external.db
Comments
///
SD Maid
Version:
4.14.18 (41418)
Unlocker:
4.3.8 (40308) (true)
Device
Root:
RootContext(rootState=Root(state=ROOTED)
Fingerprint: /// OnePlus 6 on OOS Open Beta 19 - which is a near-AOSP variant of Android 9
The text was updated successfully, but these errors were encountered: