New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Localization not work under iOS and Mac arm64 #16847
Comments
From @rachelkang on Fri, 18 Nov 2022 15:05:14 GMT @rolfbjarne thoughts? |
From @rolfbjarne on Fri, 18 Nov 2022 16:11:40 GMT
Your test project doesn't seem to contain any
does it work for you if you build from the command line? If not, can you get a binary buildlog so that we can investigate where things go wrong for you? |
From @changguangyu on Sat, 19 Nov 2022 00:57:53 GMT This is my build command: The uk subdirectory at Here is my build log. |
From @changguangyu on Mon, 21 Nov 2022 01:01:56 GMT The issue also exists in iOS App Store distribution package(but does not appear when test the app in both debug and release mode, physical device and stimulator). I think MAUI is not a proper choice for production at this time. Not because bugs of MAUI, but the difference between the final distribution package and release mode package, which makes MAUI totally not reliable. |
From @changguangyu on Mon, 21 Nov 2022 03:09:28 GMT Edit: Tested again. On iOS App Store distribution package it is another issue. |
From @changguangyu on Mon, 21 Nov 2022 05:18:45 GMT Still cannot solve this issue. |
From @changguangyu on Mon, 21 Nov 2022 05:41:10 GMT Temporary Fix for Mac: Add |
I can reproduce the problems when building a universal Mac Catalyst app (which is now the default for Release builds). There are at least two factors contributing to the problem:
Things we'll probably need to do:
|
…amarin#16847. If we're creating a universal app, and here are satellite assemblies that are not identical across all RuntimeIdentifiers, those assemblies will be stored in a RuntimeIdentifier-specific subdirectory during the build. Unfortunately we didn't know how to find those assemblies at runtime, causing localizations in universal apps to not work. This change will: * Add support for looking in the directory where RID-specific satellite assemblies are stored. * Add an assembly resolution event handler to our CoreCLR bridge so that we can execute our custom lookup code. * Add a assembly resource lookup test to monotouch-test. * Add a macOS + Mac Catalyst variation of monotouch-test to xharness that triggers the bug (a universal test app). Fixes xamarin#16847.
I've moved this to its own issue: #17115. |
…amarin#16847. If we're creating a universal app, and here are satellite assemblies that are not identical across all RuntimeIdentifiers, those assemblies will be stored in a RuntimeIdentifier-specific subdirectory during the build. Unfortunately we didn't know how to find those assemblies at runtime, causing localizations in universal apps to not work. This change will: * Add support for looking in the directory where RID-specific satellite assemblies are stored. * Add an assembly resolution event handler to our CoreCLR bridge so that we can execute our custom lookup code. * Add a assembly resource lookup test to monotouch-test. * Add a macOS + Mac Catalyst variation of monotouch-test to xharness that triggers the bug (a universal test app). Fixes xamarin#16847.
…16847. (#17117) If we're creating a universal app, and here are satellite assemblies that are not identical across all RuntimeIdentifiers, those assemblies will be stored in a RuntimeIdentifier-specific subdirectory during the build. Unfortunately we didn't know how to find those assemblies at runtime, causing localizations in universal apps to not work. This change will: * Add support for looking in the directory where RID-specific satellite assemblies are stored. * Add an assembly resolution event handler to our CoreCLR bridge so that we can execute our custom lookup code. * Add an assembly resource lookup test to monotouch-test. * Add a macOS + Mac Catalyst variation of monotouch-test to xharness that triggers the bug (a universal test app). Fixes #16847.
…amarin#16847. (xamarin#17117) If we're creating a universal app, and here are satellite assemblies that are not identical across all RuntimeIdentifiers, those assemblies will be stored in a RuntimeIdentifier-specific subdirectory during the build. Unfortunately we didn't know how to find those assemblies at runtime, causing localizations in universal apps to not work. This change will: * Add support for looking in the directory where RID-specific satellite assemblies are stored. * Add an assembly resolution event handler to our CoreCLR bridge so that we can execute our custom lookup code. * Add an assembly resource lookup test to monotouch-test. * Add a macOS + Mac Catalyst variation of monotouch-test to xharness that triggers the bug (a universal test app). Fixes xamarin#16847.
From @changguangyu on Fri, 18 Nov 2022 13:22:22 GMT
Description
Localization not work under iOS and Mac arm64.
It seems that
<GenerateSatelliteAssembliesForCore>true</GenerateSatelliteAssembliesForCore>
under these platform is broken.The satellite assemblies are not included in output app package.
Right click 'Show package contents' on output Mac app, the satellite assemblies folder(e.g. zh-Hans) inside MonoBundle directory are empty. There should be ProjectName.resources.dll.
Steps to Reproduce
For Windows and Android, switch language is working fine, but on iOS and Mac arm64 it's not work.
The satellite assemblies are not included in output app package.
It seems that
<GenerateSatelliteAssembliesForCore>true</GenerateSatelliteAssembliesForCore>
is broken.Link to public reproduction project repository
https://github.com/VladislavAntonyuk/MauiSamples/tree/main/MauiLocalization
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
iOS, macOS
Affected platform versions
Mac x64 is working fine, arm not work
Did you find any workaround?
No response
Relevant log output
No response
Copied from original issue dotnet/maui#11474
The text was updated successfully, but these errors were encountered: