Forum Discussion
MSIX Packages with WebView2 Dependency now fail to install
I detected this happening starting over Thanksgiving weekend.
Packages that have the WebView2 external dependency, including packages that worked just before the holiday, fail to install currently.
The following was posted to the WebView2 folks, who suggested it be posted here, however the poster seemed to have issues and I am adding a link to their original post here: MSIX WebView2 ExternalDependency failing to install/update. - Microsoft Q&A It is a pretty good writeup up the issue.
My own notes:
This may be related to an issue that has also cropped where winget is currently requiring the --allow... parameters rather than allowing you to accept once. So possibly this causes the implementation of the detected install to fail.
This has been tested against systems with the latest version of the WinView2 package already installed, and the packages that reference still fail to install.
There has also been a suggestion on linkedIn that it might be related to a known WindowsAppSDK issue "There is a known issue with the WinAppSDK 1.6.2 package.
https://portalfuse.io/blog/portalfuse-weekly-security-update-november-26-2024 "
Finally I'll note that web searches find a similar sounding issue occurred two years ago at the end of November.
1 Reply
Providing more information about the issue AND A WORKAROUND.
NOTE: It does appear that Microsoft has solved the generic winget issue I mentioned that required the --accept parameters on newly patched systems today. But the reported problem of installing an MSIX package with the WebView2 dependency remains.
When installing a package which includes the WebView2 external dependency (and associated Capability declaration) in the AppXManifest:
- On Windows 11 23H2
- AppInstaller version 1.24.25200.0
The AppInstaller fails to install with the following reason:
App Installer failed to install package dependencies. Ask the developer for package Microsoft.WebView2.
Get-AppXLog and Get-AppXLastError return nothing.
In the AppXPackagingOM Information log we see the following with Event ID 216:
App manifest validation warning: Declared namespace http://schemas.microsoft.com/appx/manifest/externaldependencies is inapplicable, it will be ignored during manifest processing.
I believe the above message is misleading as I see signs of the externaldepency attempting to be processed, but to be clear that the namespace should be applicable I point to the documentation win32dependencies:ExternalDependency (Windows 10, Windows 11) - Windows UWP applications | Microsoft Learn which has the following requirements listed in the remarks section:
This feature requires that Microsoft App Installer version 1.16.12651.0 or later be installed on the target machine.
Manually installing the winget package without elevation fails:
PS C:\Users\admin> winget install --id Microsoft.EdgeWebView2Runtime
Found Microsoft Edge WebView2 Runtime [Microsoft.EdgeWebView2Runtime] Version 131.0.2903.70
This application is licensed to you by its owner.
Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
Downloading https://msedge.sf.dl.delivery.mp.microsoft.com/filestreamingservice/files/91530f73-1202-471b-86a9-a3b1d9655560/MicrosoftEdgeWebView2RuntimeInstallerX64.exe
██████████████████████████████ 173 MB / 173 MB
Successfully verified installer hash
Starting package install...
Installer failed with exit code: 2147747880Running the same winget command in an elevated window does succeed:
PS C:\Users\admin> winget install --id Microsoft.EdgeWebView2Runtime
Found Microsoft Edge WebView2 Runtime [Microsoft.EdgeWebView2Runtime] Version 131.0.2903.70
This application is licensed to you by its owner.
Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
Successfully verified installer hash
Starting package install...
Successfully installed.However, even with the dependency installed this does not solve the problem with an un-elevated installation of the package. We see messages in AppInstaller that it is attempting "installing required frameworks", then the same message:
App Installer failed to install package dependencies. Ask the developer for package Microsoft.WebView2.
Attempting to install the package using powershell in an elevated window now works:
add-appxpackage \\nuc7\Packages\TMEditX.5.2.0.0\WinZip_25.0.0.1_x64__xwfzvwzp69w2e.msix
Elevation was not required for installing packages with a WebView2 dependency in the past. This is a breaking change.