librecamera
librecamera copied to clipboard
[Bug] Pictures do not appear in Gallery
To reproduce
- Set image location to
/sdcard/Pictures
and ensure permissions are granted. - Take a picture.
- Tap the picture to view it in Gallery.
- Return to the Android home screen.
- Launch Gallery individually, and try to find the picture.
- Open a file manager and look for the picture in its folder.
Expected behavior
The picture appears in Gallery, just like pictures taken with other camera apps.
Actual behavior
While I can view the picture in Gallery by tapping it right after taking it, it no longer appears when I launch Gallery and search for it – neither in Timeline nor in Albums. However, the file does get created, which can be verified with a file manager. I can also tap the file in the file manager to view it with an app of my choice.
Other Information:
- App version 1.6.0, from F-Droid
- Device: Fairphone 4
- OS: Android 13 (TQ1A.230105.001.A2), LineageOS 20-20230129-NIGHTLY-FP4
- Gallery app:
com.android.gallery3d
, version 1.1.40030 (included with LineageOS 13)
Behavior may be different with other gallery apps, since this is likely due to how the gallery app detects the presence of new image files. However, this is a fairly standard gallery app, which so far has worked with any other camera app I tried – which indicates troubleshooting should begin on the camera end. After rebooting the phone, the new pictures still do not show up.
My first suspicion would be that LibreCamera fails to trigger a media scan after taking a picture, or the scan does not complete for whatever reason. (As far as I remember, there are two ways to trigger a media scan: one through a Java API call, another as an intent. I had an app where I needed to scan whenever the app crashed – the Java API method did not work, presumably since the app terminated before the scan finished, but the intent method worked.)