Key for Photo Selection Dialog won't be localized.

Hey,

Since iOS14 the user can select a subset of Photos which your app can access. When the user chooses to select that option, he will get another dialog in which he is asked to update his Selection. In this Dialog the "NSPhotoLibraryUsageDescription" Key is used again. But this time it won't get localized.

In my Info.plist I added the phrase "Photos usage description" as placeholder.
In my InfoPlist.strings I have the localizations for each supported language.

If tested several options to prevent this, but nothing changes in the repeating Dialog I always see "Photo Usage Description" and in the Initial Request for the Photo Library Access I get my localized Key.

I also tried the Option "Localized resources can be mixed" which had no effect.

Can anyone reproduce this or has a Solution for this?

I would first recommend using UIImagePickerController which doesn't require asking for permission.

If you can't, having the following should make it work:
  1. NSPhotoLibraryUsageDescription with a value in Info.plist

  2. An InfoPlist.strings file containing NSPhotoLibraryUsageDescription = "Localized Text";

  3. That InfoPlist.strings should be checked for your target, and Localization should be enabled and checked for all languages. Both are in the File inspector.

Note that the permission dialog is presented by iOS. Changing the app language in the scheme will not change the language of this dialog. To test, you have to change the iPhone preferred language.
Hi team,

Even I'm facing the same issue. We have all the necessary things mentioned above. NSPhotoLibraryUsageDescription in Info.plist and localised string in InfoPlist.strings file and the file enabled for all languages.
I main problem is that, even for the base language English in my case, for the App first launch, it is picking up the string from InfoPlist.strings file. but from the second launch, it is just displaying the constant given in the plist file.
It should pick up the actual value from the InfoPlist.strings file which is not happening.
This should definitely be an apple bug. Please let us know if there is any other alternative.

I also experience this problem,  The Photo Library Usage popup permission localized the description only for the first time it is displayed, in case the user selects the permission to select specific photos, the next time it displays the popup description display NSPhotoLibraryUsageDescription, instead of the localized string (from the InfoPlist.strings file). It happens only for the NSPhotoLibraryUsageDescription, other permissions behave as expected.

Looks like an Apple bug. Is there a way to always display the localized string?

We have the exact same problem. We set the following in Info.plist :

<key>NSPhotoLibraryUsageDescription</key>
<string>The application accesses your pictures to allow you importing them in the current intervention</string>

And we set the translated one in different languages in InfoPlist.strings, for example:

"NSPhotoLibraryUsageDescription" = "L'applicazione accede alle tue immagini per consentirti di importarle nell'intervento in corso.";

The translated message is shown the first time where you have to choose between letting the app see some of the picture or all of them. If you pick the restricted option, next time the app is used and you open the gallery you have the UNTRANSLATED message in the alert. If you set <string>NSPhotoLibraryUsageDescription</string> in the Info.plist that is all your user is going to see.

This is definitely an iOS bug. It translates OK the first time so there is no reason it wouldn't work as well later.

Same here, but it doesn't look like someone is caring :-)

Key for Photo Selection Dialog won't be localized.
 
 
Q