-
Notifications
You must be signed in to change notification settings - Fork 102
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
Investigate AddPackageAsync hangs #1720
Comments
This is easily reproducible. Just create an empty WPF app with .net 8.0 and call await packageManager.AddPackageAsync(...) it is not reproduced every time but usually on every 5 calls, hangs at least 1 time. It is only reproducible in Release Calling the method synchrously This is not reproduced in WinUI3 app (or it is possible to be much harder to be reproduced) |
We found that calling The deadlocks are reproduced ONLY with Release builds |
net48 has a different WinRT runtime, not CsWinRT. |
We are able to reproduce the deadlock with both .net8.0 and net48. I know that net core uses CsWinRT package and net48 uses Microsoft.Windows.SDK.Contracts but I am not sure where to submit a bug for Microsoft.Windows.SDK.Contracts |
We found that if we turn off optimization for (net48) in Release it works. <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<Optimize>False</Optimize>
</PropertyGroup> |
@ekalchev Are you using CsWinRT projections that you generate in net48 or are you using the built-in support? |
We are using this nuget version https://www.nuget.org/packages/Microsoft.Windows.SDK.Contracts. We tried older version and it is still reproducible. As much as I know CsWinRT nuget package can be used only with .net core 5 or later. So for net48 we use the nuget package above. Keep in mind the issue is present in both .net48 apps and .net core apps We also reproduce with with .net8 app and using If you can't reproduce it, we can provide a code that reproduce it. |
Determine whether issue still repros with recent version and investigate:
dotnet/wpf#4097
The text was updated successfully, but these errors were encountered: