WindowsAppSDK
WindowsAppSDK copied to clipboard
Unable to run published msixbundle due to application crashes at start
Describe the bug
When trying to run a published application it crashes at startup
Application: Capster.exe
CoreCLR Version: 8.0.824.36612
.NET Version: 8.0.8
Description: The process was terminated due to an unhandled exception.
Exception Info: System.TypeInitializationException: The type initializer for '<Module>' threw an exception.
---> System.TypeInitializationException: The type initializer for 'WinRT.TypeNameSupport' threw an exception.
---> System.TypeLoadException: Could not load type 'System.Collections.Generic.List`1' from assembly 'System.Collections, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
at WinRT.TypeNameSupport..cctor()
--- End of inner exception stack trace ---
at WinRT.ProjectionInitializer.InitalizeProjection()
--- End of inner exception stack trace ---
at Capster.Program.Main(String[] args)
Steps to reproduce the bug
Create a winui3 application in visual studio Publish the application Install & run
Expected behavior
No response
Screenshots
No response
NuGet package version
Windows App SDK 1.5.6: 1.5.240802000
Packaging type
No response
Windows version
No response
IDE
No response
Additional context
No response
I've updated to Windows App SKD 1.6, and now the error are different:
Application: Capster.exe
CoreCLR Version: 8.0.824.36612
.NET Version: 8.0.8
Description: The process was terminated due to an unhandled exception.
Exception Info: System.MissingMethodException: Method not found: 'Void System.Runtime.CompilerServices.IAsyncStateMachine.SetStateMachine(System.Runtime.CompilerServices.IAsyncStateMachine)'.
at Capster.Program.Main(String[] args)
at Capster.Program.<Main>(String[] args)
Hi @k1mmm, can you share your project so that I can repro and analyze from my end.
I've tested this in latest Visual Studio (17.12.3) with Windows App SDK 1.6 and it's working, so I'm closing this!