Photo picker does not open with compile sdk 33 (Android 13)
See original GitHub issueDescribe the bug App picker does not open with compile sdk 33 after permission handling Tested with version 32 (Android 12) and it works
Sample code:
` val launcher = rememberLauncherForActivityResult(ActivityResultContracts.StartActivityForResult()) { if (it.resultCode == Activity.RESULT_OK) { onAvatarChanged(it.data?.data!!) } }
AvatarImageUI(
initials = firstName?.take(2) ?: "",
avatarUri = avatarUrl,
fontSize = 50.sp,
canEdit = canEditAvatar,
onEditClick = {
ImagePicker.with(activity)
.maxResultSize(maxAvatarSize, maxAvatarSize)
.cropSquare()
.provider(ImageProvider.BOTH)
.setOutputFormat(
if (Utils.isAtleastR()) Bitmap.CompressFormat.WEBP_LOSSY else Bitmap.CompressFormat.WEBP
)
.createIntentFromDialog { launcher.launch(it) }
},
size = Constants.Size.AVATAR_BIG,
)`
Looking forward to you comments. Thank you in advance
Issue Analytics
- State:
- Created a year ago
- Comments:15 (8 by maintainers)
Top Results From Across the Web
New Photo Picker on Android 13/API Level 33 - YouTube
... try restarting your device. Your browser can't play this video. ... New Photo Picker on Android 13 / API Level 33 -...
Read more >Photo picker | Android Developers
The photo picker provides a browsable, searchable interface that presents the user with their media library, sorted by date from newest to oldest....
Read more >Android 13 Photo Picker With The Activity Result API - Medium
1. Setup. The Photo Picker requires your app to target at least version 33 of the Android SDK. To comply with this requirement,...
Read more >How Google is backporting Android 13's Photo Picker
Google made the Photo Picker APIs public a couple of months ago, but in order to use them, an app needs to be...
Read more >What library is needed for Photo Picker of Android 13?
API 32 is Android 12L, not Android 13. You need to follow the Set up the Android 13 SDK instructions to use Android...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hey, I can confirm that 2.3.20 works fine now! I guess my PR is no longer needed then?
Tried it on the sample app and it works fine, UNTIL I switch the dependency from the local module to the latest maven artifact:
By doing so, the sample app again tells me that the storage permission is required.
If I look at the downloaded apk sources (or try to look at
GalleryProvider
inside AS), I can see the latest changes includingREAD_MEDIA_IMAGES
. But as soon as I decompile the actual aar, all the latest changes are missing.Looking at the report on jitpack, it also says
ERROR: No build artifacts found
at the very end, so maybe something’s wrong with publishing?Just to be safe I also tried clearing all my caches, but the problem still persists.