After updating Windows 10, Windows can no longer manage any appx packages, and I can't deploy WinUI 3 apps from VS
I just updated ~Visual Studio to 17.13.0 Preview 1 and~ Windows to 19045.5131.
Now Visual Studio can no longer deploy WinUI 3 apps, I can't uninstall any apps, the Microsoft Store can't update any apps, and trying a different account also results in the Store malfunctioning.
It seems Windows has lost its ability to manage packages.
@DrusTheAxe From what I've seen you are an expert in this area. Any suggestions for how to approach this?
VS error is:
DEP0900: Failed to unregister application "myappid". [0x80073CFA]
Can confirm. All our devs with win10 22H2 19045.5131, 19045.5011 machines faced with this issue. No problems for devs with win11 23H2 and above.
Just quick note, I think Visual Studio update is not the reason of this issue. We faced it on VS 17.9.7.
Related .NET MAUI topic: https://github.com/dotnet/maui/issues/25832
We experienced the same issue and identified Windows update KB5046613 as the cause.
Uninstalling KB5046613 does not help
Every time.
"I think I'll update some packages. I may as well update VS while I'm at it. Oh, it suggests a restart. Ah, Windows wants to update during the restart."
~
"I wonder how much time & money this is going to cost me."
Only "solution" I've found is a clean install, which isn't a solution at all. Maybe now that millions are impacted Microsoft will throw together some sort of fix...
Same problem here, how you "clean install" ? i am noobie in C# development. Do you click "Clean Solution" and Rebuild ?
@S4nt1ag0 clean install the whole OS. while im at it, im installing win11. it seems that win10 is really dying already.
#MeToo right after Windows update.
I had this issue with .NET 8 and Windows 10 22H2 19060.1000.0. Upgrading to Windows 11 was unfortunately the only thing that worked.
I'm currently having this issue on Win10 22H2 builds 19045.5011 and 19045.5131. We started noticing this issue on 11/12.
@subratb That looks like a different issue, and it is a month old. This one is brand new this week.
Experiencing the same here. Pretty much dead in the water until a fix is released. All development has been blocked.
@StevoSM You can just stick this in your csproj files to make them unpackaged until a fix is available - unless they require something only packages support.
<WindowsAppSDKSelfContained>true</WindowsAppSDKSelfContained>
<WindowsPackageType>None</WindowsPackageType>
I am now having same issue.
I added the above lines to my project file, first in an existing property group, now in their own as follows:
Restarted Visual Studio, did a Clean and Rebuild Solution, but still get
even though deploy option is set
@johnt-star You need to change your configuration selection to Unpackaged.
Thanks kmgallahan!
I no longer get the deployment error dialog after changing to Unpackaged.
Unfortunately after upgrading Visual Studio to the latest version, updating nuget packages where appropriate and installing .Net 9, I am now getting exceptions for things that use to work.
At least I can see what has changed and hopefully resolve them in order to get my app running again.
Appreciate the help!
One thing I had to do was add this to resolve some ref issues:
<OutputPath>$(SolutionDir)bin\$(Configuration)\</OutputPath>
There was an issue in the WinAppSDK 1.6.2 release which affected Windows 10 version 19045 machines. The 1.6.2 release has been pulled to prevent more machines being impacted.
This issue was not caused by an update to Windows and will not be fixed by uninstalling any Windows Cumulative Updates.
There is an upcoming Windows Update which will fix this issue (adding extra safety in Windows), and a release of WinAppSDK 1.6.3 is coming soon with a fix.
Machines in a bad state can also be manually fixed by running these steps:
- Launch a PowerShell or Command Prompt as Administrator and run these commands:
takeown /F "C:\Program Files\WindowsApps\Microsoft.WindowsAppRuntime.1.6_6000.311.13.0_x64__8wekyb3d8bbwe\WindowsAppRuntime.DeploymentExtensions.OneCore.dll"
icacls "C:\Program Files\WindowsApps\Microsoft.WindowsAppRuntime.1.6_6000.311.13.0_x64__8wekyb3d8bbwe\WindowsAppRuntime.DeploymentExtensions.OneCore.dll" /grant Administrators:F
del "C:\Program Files\WindowsApps\Microsoft.WindowsAppRuntime.1.6_6000.311.13.0_x64__8wekyb3d8bbwe\WindowsAppRuntime.DeploymentExtensions.OneCore.dll"
takeown /F "C:\Program Files\WindowsApps\Microsoft.WindowsAppRuntime.1.6_6000.311.13.0_x86__8wekyb3d8bbwe\WindowsAppRuntime.DeploymentExtensions.OneCore.dll"
icacls "C:\Program Files\WindowsApps\Microsoft.WindowsAppRuntime.1.6_6000.311.13.0_x86__8wekyb3d8bbwe\WindowsAppRuntime.DeploymentExtensions.OneCore.dll" /grant Administrators:F
del "C:\Program Files\WindowsApps\Microsoft.WindowsAppRuntime.1.6_6000.311.13.0_x86__8wekyb3d8bbwe\WindowsAppRuntime.DeploymentExtensions.OneCore.dll"
- Reboot
- Launch a PowerShell as Administrator and run these commands:
Get-AppxPackage *WinAppRuntime.Main.1.6* -AllUsers | Where { $_.Version -eq '6000.311.13.0' } | Remove-AppxPackage -AllUsers
Get-AppxPackage *MicrosoftCorporationII.WinAppRuntime.Singleton* -AllUsers | Where { $_.Version -eq '6000.311.13.0' } | Remove-AppxPackage -AllUsers
Get-AppxPackage *Microsoft.WinAppRuntime.DDLM* -AllUsers | Where { $_.Version -eq '6000.311.13.0' } | Remove-AppxPackage -AllUsers
Get-Appxpackage *WindowsAppRuntime.1.6* -AllUsers | Where { $_.Version -eq '6000.311.13.0' } | Remove-AppxPackage -AllUsers
Investigations are continuing and we'll provide further updates when available.
If you have an app project referencing the Microsoft.WindowsAppSDK package version 1.6.241106002, update the project to instead reference version 1.6.240923002. Removing version 1.6.241106002 from your local NuGet cache (such as C:\Users\<username>\.nuget\packages\microsoft.windowsappsdk\1.6.241106002) is also recommended to avoid accidental usage.
Investigations are continuing and we'll provide further updates when available.
@codendone Thanks for the update. I don't know how helpful this might be, but we are only on WinAppSDK 1.4 and are experiencing the issue. We have not yet updated to 1.6 at all. In our environment, it must be the result of a Windows update or possibly that combined with a Visual Studio 2022 update. Note also we cannot run Slack as it is in a state of needing to be updated by the Windows Store app, and the Windows Store app is not able to successfully complete app updates due to this same issue.
@StevoSM There must be a different app on the system which is using 1.6. Running Get-Appxpackage *WindowsAppRuntime.1.6* -AllUsers in an administrative PowerShell can help see those.