Bug report (I searched for similar issues and did not find one)
In release, the app crashes on Android device after the blank screen before opening the main page.
The main page should display as in Debug without any crashed.
Brand new project from Uno template.
Nuget Package: Uno.UI
Package Version(s): 1.44.0
Affected platform(s):
Visual Studio
Relevant plugins
Thanks for reporting the issue! I tried creating the issue with the same repro as yours, and I cannot reproduce the issue.
Could you provide the exact solution you've created, as we may have missed something there. Also which version of Android are you running on ?
Thanks!
Thank you for looking into it.
Project that crashes:
https://github.com/FrancoisM/ReproUnoTemplateCrashInReleaseInAndroid
The device is a Samsung S9 running Android version: 9
Thanks, could you also paste the exception you're getting from AppCenter ? It is the same that the one on gitter ?
I successfully reproduced the problem on a Google Moto G7 device.
The problem is related to the "LLVM AOT Optimization". You may disable it to fix your problem.
Microsoft knows about this problem and it has already been fixed in latest _Preview_ version of Visual Studio 2019 (more details here).
If you need to use it from the current version of VisualStudio, please set this in your _csproj_ file: <EnableLLVM>false</EnableLLVM>
Hi @carldebilly, how did you find out? Once you reproduced the issue, where did you get any info about the problem? Which log did you look into? What error did you see and were?
Thank you for your help, I'd like to learn from this 馃憤
Hello @FrancoisM, the problem was obviously coming from something done only in _Release_ mode. Usually it's related to eiter _linking_ or the _AOT_ processing.
I deactivated the _AOT_ and the problem were gone... so my last check was to check if it's related to the LLVM optimisation and bingo! After that a quick search on the web and I found the link I sent to you.
Last step was to check in 2019 Preview and I confirmed the problem was solved there... :-)
Tks. Reasoning makes sense.
I thought maybe there was an error message in a place I didn't know about.
Anyway, too bad they don't host previews on pipelines ;-)
The workaround will be to have your own build agent or to temporary deactivate the LLVM optimization.
This bug seems present only on Android 9.
Most helpful comment
Hello @FrancoisM, the problem was obviously coming from something done only in _Release_ mode. Usually it's related to eiter _linking_ or the _AOT_ processing.
I deactivated the _AOT_ and the problem were gone... so my last check was to check if it's related to the LLVM optimisation and bingo! After that a quick search on the web and I found the link I sent to you.
Last step was to check in 2019 Preview and I confirmed the problem was solved there... :-)