-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
HybridWebView crashes Maui App built with .Net 9.0.1 GA / Windows on ARM / 23H2 #26116
Comments
I have encountered this as well in Parallels in a M2 Mac. I was going to add a bug for it, but I see this one was just added. This is likely a pretty major issue as likely the majority of people who are doing MAUI development are doing so on Macs due to iOS restrictions. That means Parallels on an Silicon chip which is based on ARM if they want to cross platform to a Windows app. This also leads me to believe such apps will not run on an ARM based machine, regardless of where they were developed and compiled. I.e. this bug will prevent it from running on many of Microsoft's own new devices. System Information Parallels Desktop for Mac Version 20.1.1 (55740) Windows 11 Pro 23H2 Relevant log output Exception: |
This also brings up another thought. The team added a lot of automated regression testing for MAUI as part of .Net 9. That is great and I love seeing it. My further question is, are the automated tests for Windows sections of the framework running on Intel and ARM based machines? If not, that may represent a gap in the automated testing. |
When I created this bug report, I wasn't sure if this happens to all Windows on ARM laptops, or just a subset of them. But if the former then I agree with @Bowman74 that this is pretty bad. Anybody using any of the new Copilot+ Windows PCs (e.g., Surface Pro 7, Surface Laptop 7, ...), or an M* series Mac MBP / Air / Studio / Mini, for Maui development is going to be blocked from using the new HybridWebView control. |
Also, to be clear on a Mac I can run in Android and iOS MAUI apps just fine (I haven't tried MacOS apps yet). It is only when I deploy to Windows and try to run it as a Windows app in Windows that I get this error. I assume MS wants the apps to work in Windows on ARM machines. :) Also it compiles without a hitch. The error is a runtime error. |
I did verify it works correctly in MacCatalyst as well. It is only an issue when running in Windows in some flavor of ARM processor. |
Description
Build any .Net MAUI App that has a page with a HybridWebView control on a Windows ARM laptop running .Net 9.0.1 and Windows 11 23H2. Navigating to that page causes an Unhandled Exception in App.g.i.cs. This is true even if you just run the .Net Maui sample app for HybridWebView, or the code on the online documentation for HybridWebView.
This was working fine in .Net 9 RC1 and RC2 on the same laptop - and so this appears to be a regression in .Net 9 GA. Uninstalling / reinstalling Visual Studio and .Net SDK doesn't change this behavior.
The same Maui Sample App for HybridWebView doesn't crash on a Windows 11 x86 laptop running 24H2 - so this might happen only for Windows on ARM, or 23H2 version of Windows 11.
Steps to Reproduce
https://github.com/dotnet/maui-samples/tree/main/9.0/UserInterface/Views/HybridWebViewDemo
Link to public reproduction project repository
https://github.com/dotnet/maui-samples/tree/main/9.0/UserInterface/Views/HybridWebViewDemo
Version with bug
9.0.10 SR1
Is this a regression from previous behavior?
Yes, this used to work in .NET MAUI
Last version that worked well
9.0.0-rc.2.24503.2
Affected platforms
Windows
Affected platform versions
Windows 11 23H2 ARM64 , Target Windows SDK Framework 10.0.19041.0, Min Target 10.0.17763.0
Did you find any workaround?
Build and run the same app on a different laptop running Windows 11 24H2 x86. So switching from Windows ARM to Windows x86, and from 23H2 to 24H2, prevents the crash.
Relevant log output
The text was updated successfully, but these errors were encountered: