Resx file does not produce designer file, application is crashing
See original GitHub issueDescription
Hello there!
I’m in the process of migration TaskLoaderView to MAUI, it was going alright till I launch the app for the first time.
It crashed right after the Splashscreen.
It was complaining about my resx file (located in Resources\Localization\SampleResources.resx
), not being embedded in the resources…
After that I tried a few things, and now it seems even worst: it crashes before the splash, when loading resources assemblies:
[monodroid-assembly] open_from_bundles: failed to load assembly en-US/Retronado.Maui.resources.dll
[monodroid-assembly] open_from_bundles: failed to load assembly en-US/Retronado.Maui.resources.dll
[monodroid-assembly] open_from_bundles: failed to load assembly en/Retronado.Maui.resources.dll
[monodroid-assembly] open_from_bundles: failed to load assembly en/Retronado.Maui.resources.dll
[.retronado.mau] * Assertion: should not be reached at /__w/1/s/src/mono/mono/mini/mini-exceptions.c:456
[libc] Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 9031 (.retronado.maui), pid 9031 (.retronado.maui)
I think it is related to the resx file, cause It fails to generate the design file when building the project on Rider EAP AND on VS Mac Preview.
Steps to Reproduce
Here is the repo sample:
https://github.com/roubachof/Sharpnado.TaskLoaderView/tree/failing-resx
- Project is
Retronado.Maui
- The resx is
Resources\Localization\SampleResources.resx
Version with bug
6.0 (current) VS for Mac preview 17.3 build 191
Last version that worked well
Unknown/Other
Affected platforms
Android, I was not able test on other platforms
Affected platform versions
Android 21 and up, probably iOS, since resx doesn’t generate anything
Did you find any workaround?
nope
Relevant log output
No response
Issue Analytics
- State:
- Created a year ago
- Reactions:2
- Comments:21 (7 by maintainers)
Top GitHub Comments
So the error is:
I see the
.resources
file in here with a different name:The file in there matches the
$(RootNamespace)
of this project:Are you somehow bringing in the source code for this class within this assembly?
I don’t really understand how these projects are setup, but it looks like
Samples.csproj
is expecting the.resources
file to be named based on its$(RootNamespace)
. Your app has the$(RootNamespace)
ofRetronado.Maui
.We have some tests in .NET 6 for
.resx
, so it seems like they are generally working:https://github.com/xamarin/xamarin-android/blob/main/tests/Mono.Android-Tests/Localization/LocalizationTests.cs
I think this was fixed, if not, please let us know!