I've got a weird issue with Visual Studio 2019.
For some reason building my app in Release mode doesn't work. It shortly shows the app's splash screen, and then Visual Studio gives this error:
Unhandled exception at 0x00007FF917E94B89 (KernelBase.dll) in [appname].exe: 0xE0434352 (parameters: 0xFFFFFFFF80070002, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000, 0x00007FF904910000).
Followed by this error dialog, if I press the continue button:
An issue in the [appname].exe process caused it to fail to activate. This process threw one or more exceptions.
Use Debug->Windows->Exception Settings to configure the debugger to stop when these exceptions are thrown. More information can be found in the Debug pane of the Output Window (Debug->Windows->Output).
The weird thing is, building in Debug mode works fine, and building and deploying to the Microsoft Store is also without problems.
I've cleaned the obj and bin folders, updated Visual Studio and all used nuget packages, reinstalled Visual Studio... Any clues?