social-app
social-app copied to clipboard
Gallery access to all images in local files is dependent on Android version
Describe the bug When you add an image to your post on a mobile device, you can add it from a folder in your local files. On Android devices with Android version below 12, you can access all images in all folders, including folders you create yourself, but on devices with Android 12 and above, you can access only the default Android folders Camera, Screenshots, and Downloads.
To Reproduce
Steps to reproduce the behavior:
(Expected behavior with Android <12 and unexpected with Android >12).
- Create a post by clicking the icon at the bottom right.
- Then click the left icon to add an image.
- Then click on 'Album'.
Expected behavior
You should be able to access all images in all folders, including those you have created yourself.
Details
- Platform: Android
- Platform version: 9 (Works as expected),11 (Works as expected),12 (bug),13 (bug)
- BlueSky App version: 1.51.0
This appears to partially be an issue with Android itself. As someone experiencing this bug, the same issue occurs when trying to upload images to mobile sites like Facebook or Craigslist. However, on mobile websites I am given the option to tap three dots to expand the "browse" menu which lets me find the rest of my folders. On Bluesky this option does not exist. A custom media gallery for the app itself would be great, but in the interim giving us access to this "browse" window would absolutely be an acceptable solution.
I suspect it's the partial photo permissions update they've rolled out in Android, and given that this is using Expo, that hasn't updated and is running in compatibility mode because it's using the READ_MEDIA_IMAGES
permission instead of the new READ_MEDIA_VISUAL_USER_SELECTED
permission.
I have no idea how to fix this without doing away with Expo's image picker altogether, but truly this bug makes posting images SUPER annoying.
More reports https://www.reddit.com/r/BlueskySocial/comments/16db4lp/problem_uploading_photos
I suspect it's the partial photo permissions update they've rolled out in Android, and given that this is using Expo, that hasn't updated and is running in compatibility mode because it's using the
READ_MEDIA_IMAGES
permission instead of the newREAD_MEDIA_VISUAL_USER_SELECTED
permission.
If I understand correctly, it's just one line of code that needs to be changed, right? So would it be possible to clone the repo and just fix that one line?
I haven't been able to find any information about this so far, @aendra-rininsland it sounds like we need to open an issue with expo
https://www.reddit.com/r/BlueskySocial/comments/17qgi6c/still_cannot_access_photos_on_my_phone
@pfrazee Might be this issue: https://github.com/expo/expo/issues/25361 or this PR https://github.com/expo/expo/pull/20907
Are you using the latest version of the image picker? It seems they fixed that back in January.
Edit: Here's another, open issue discussing this; there are a bunch linked to the above PR https://github.com/expo/expo/issues/24122
Looks like they are using PickVisualMedia
instead of GetContent
. Let me see if I can create a patch to get around this. A brief test let me access Browse and select an image from Files. (Give Android Studio about 40 minutes to figure itself out...)
Good news! 🎉