androidandroid-permissionsandroid-14

Does READ_MEDIA_VISUAL_USER_SELECTED permission is added automatically to the app manifest when requesting READ_MEDIA_IMAGES permission on android 14?


On Android 14 there is a new storage access permission, according to the doc: https://developer.android.com/reference/android/Manifest.permission#READ_MEDIA_VISUAL_USER_SELECTED

This permission will be automatically added to an app's manifest if the app requests READ_MEDIA_IMAGES, READ_MEDIA_VIDEO, or ACCESS_MEDIA_LOCATION regardless of target SDK.

I tested this on my app, the target SDK is 33, using READ_MEDIA_IMAGES and READ_MEDIA_VIDEO in my manifest.

On Pixel 5, Android 14, security patch level: Oct 5 2023, I got the new permission on my app. enter image description here

Than I updated the device, Android 14, security patch level: Nov 5 2023, and the new permission is gone and it is now like on Android 13. Tested also after factory reset. enter image description here

On Samsung Galaxy S23 Ultra, security patch level: Oct 1 2023 I Don't get the new permission automatically at all. enter image description here

Did Google add this change without target SDK to everyone at first, and than saw how many problems it makes for apps that don't support it yet and rolled it back without updating the doc?

It is very inconsistent right now when requesting storage access on android 14.

Android 14 storage permission with access to specific images and videos is not automatically added to manifest.


Solution

  • Seem Google has changed this handling:

    Apps that target API below 34 must add READ_MEDIA_VISUAL_USER_SELECTED in their manifest.

    Checkout this resource: https://issuetracker.google.com/issues/310770781#comment10