-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Open
Labels
Issue-BugIt either shouldn't be doing this or needs an investigation.It either shouldn't be doing this or needs an investigation.
Description
Brief description of your issue
This is somewhat related to #1808 but for installer log files. Because winget sets the log location to an already deep path, the log files that get created by the installer can more easily run into the 260 path length limit of Windows.
In the repro below, the installer attempts to create a log with the path of C:\Users\WDAGUtilityAccount\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir\WinGet-Microsoft.dotnet.6.1.322.12413-2022-03-22-14-16-07.487_013_Microsoft.NET.Sdk.Android.Manifest_6.0.100.31.0.101_preview.9.16_x64.msi.log which is over the path length limit.
Steps to reproduce
git clone https://github.com/microsoft/winget-pkgs.gitcd winget-pkgsgit checkout 5e9640f.\Tools\SandboxTest.ps1 manifests\m\Microsoft\DotNet\6.1.322.12413
Expected behavior
.NET SDK should be successfully installed in Windows Sandbox environment.
Actual behavior
Install fails.
Output:
--> Installing WinGet
Tip: you can type 'Update-EnvironmentVariables' to update your environment variables, such as after installing a new software.
--> Configuring Winget
Admin setting enabled.
--> Installing the Manifest 6.1.322.12413
Found Microsoft .NET SDK [Microsoft.dotnet] Version 6.1.322.12413
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://dotnetcli.azureedge.net/dotnet/Sdk/6.0.103/dotnet-sdk-6.0.103-win-x64.exe
██████████████████████████████ 187 MB / 187 MB
Successfully verified installer hash
Starting package install...
Installer failed with exit code: 87
Installer log is available at: C:\Users\WDAGUtilityAccount\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir\WinGet-Microsoft.dotnet.6.1.322.12413-2022-03-22-14-16-07.487.log
--> Refreshing environment variables
--> Comparing ARP Entries
DisplayName DisplayVersion Publisher ProductCode
----------- -------------- --------- -----------
Microsoft ASP.NET Core 6.0.3 Targeting Pack (x64) 6.0.3.22124 Microsoft Corporation {EA11EC08-4D6C-3AA8-86BB-3FC200EF074C}
Relevant output from the installer log file:
[02B0:02B8][2022-03-22T14:16:39]e000: Error 0x80070057: Failed to enable logging for package: Microsoft.NET.Sdk.Android.Manifest_6.0.100.31.0.101_preview.9.16_x64.msi to: C:\Users\WDAGUtilityAccount\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir\WinGet-Microsoft.dotnet.6.1.322.12413-2022-03-22-14-16-07.487_013_Microsoft.NET.Sdk.Android.Manifest_6.0.100.31.0.101_preview.9.16_x64.msi.log
[02B0:02B8][2022-03-22T14:16:39]e000: Error 0x80070057: Failed to execute MSI package.
[13C0:13C4][2022-03-22T14:16:39]e000: Error 0x80070057: Failed to configure per-machine MSI package.
Environment
Windows Package Manager v1.2.10271
Copyright (c) Microsoft Corporation. All rights reserved.
Windows: Windows.Desktop v10.0.22000.556
Package: Microsoft.DesktopAppInstaller v1.17.10271.0anatolybolshakov, chklauser, TheBestPessimist and mrEDitor
Metadata
Metadata
Assignees
Labels
Issue-BugIt either shouldn't be doing this or needs an investigation.It either shouldn't be doing this or needs an investigation.