Open
Description
Description
Hi,
Can you please check with sample code attached,
why UnhandledException not work in reeased mode after publish.
public partial class App : Application {
public App() {
InitializeComponent();
AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
}
private async void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e) {
try { } catch (Exception) { } }
Steps to Reproduce
- Open the attached app.
2..Publish it in cmd.
dotnet publish -f net8.0-windows10.0.19041.0 -c Release -p:WindowsPackageType=None -p:WindowsAppSDKSelfContained=true - -p:RuntimeIdentifierOverride=win10-x64
3.Throw exception from one of pages.
4.Unhandled exception not fire?
Link to public reproduction project repository
......
Version with bug
8.0.3 GA
Is this a regression from previous behavior?
No, this is something new, Not sure, did not test other versions
Last version that worked well
Unknown/Other
Affected platforms
Windows
Affected platform versions
.....
Did you find any workaround?
No
Relevant log output
No