-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Description
Please confirm these before moving forward
- I have searched for my issue and not found a work-in-progress/duplicate/resolved issue.
- I have not been informed if the issue is resolved in a preview version of the winget client.
Category of the issue
Installation issue.
Brief description of your issue
I tried installing the installing the package, but the installer failed with exit code 5. I reviewed the installer log and noticed a line that said it failed to close an application, but HWiNFO wasn't running anymore, so I just reran the install command and it completed successfully. I have no idea how common it is for this error to occur, but I'm guessing people don't usually bother to create an issue about it since it resolves itself by running the command a second time.
Steps to reproduce
- I initially installed HWiNFO from the website, but I doubt that's relevant aside from the fact that it was installed and running.
- Run
winget install --id REALiX.HWiNFO -e
Actual behavior
PowerShell 7.5.0
Loading personal and system profiles took 2362ms.
~ ❯ winget search HWiNFO
Name Id Version Match Source
----------------------------------------------------
HWiNFO® REALiX.HWiNFO 8.22 Moniker: hwinfo winget
~ ❯ winget install --id REALiX.HWiNFO -e
Found an existing package already installed. Trying to upgrade the installed package...
Found HWiNFO® [REALiX.HWiNFO] Version 8.22
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://sourceforge.net/projects/hwinfo/files/Windows_Installer/hwi64_822.exe/download
██████████████████████████████ 17.7 MB / 17.7 MB
Successfully verified installer hash
Starting package install...
The installer will request to run as administrator, expect a prompt.
You cancelled the installation.
Installer failed with exit code: 5
Installer log is available at: C:\Users\LocalUser\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir\WinGet-REALiX.HWiNFO.8.22-2025-03-11-09-31-36.112.log
~ ❯ cat C:\Users\LocalUser\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir\WinGet-REALiX.HWiNFO.8.22-2025-03-11-09-31-36.112.log
2025-03-11 09:31:39.784 Log opened. (Time zone: UTC-04:00)
2025-03-11 09:31:39.784 Setup version: Inno Setup version 6.3.3
2025-03-11 09:31:39.784 Original Setup EXE: C:\Users\LocalUser\AppData\Local\Temp\WinGet\REALiX.HWiNFO.8.22\download.exe
2025-03-11 09:31:39.784 Setup command line: /SL5="$A0E9C,17609004,840192,C:\Users\LocalUser\AppData\Local\Temp\WinGet\REALiX.HWiNFO.8.22\download.exe" /SPAWNWND=$30848 /NOTIFYWND=$90BE0 /SP- /SILENT /SUPPRESSMSGBOXES /NORESTART /LOG="C:\Users\LocalUser\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir\WinGet-REALiX.HWiNFO.8.22-2025-03-11-09-31-36.112.log"
2025-03-11 09:31:39.784 Compatibility mode: Yes (Installer)
2025-03-11 09:31:39.784 Windows version: 10.0.26100
2025-03-11 09:31:39.784 Windows architecture: x64 (64-bit)
2025-03-11 09:31:39.784 Machine types supported by system: x86 x64
2025-03-11 09:31:39.784 User privileges: Administrative
2025-03-11 09:31:39.786 Administrative install mode: Yes
2025-03-11 09:31:39.786 Install mode root key: HKEY_LOCAL_MACHINE
2025-03-11 09:31:39.786 64-bit install mode: Yes
2025-03-11 09:31:39.787 Created protected temporary directory: C:\Users\LocalUser\AppData\Local\Temp\is-8AGQF.tmp
2025-03-11 09:31:39.938 Found 1 files to register with RestartManager.
2025-03-11 09:31:39.938 Calling RestartManager's RmGetList.
2025-03-11 09:31:39.979 RmGetList finished successfully.
2025-03-11 09:31:39.979 RestartManager found an application using one of our files: HWiNFO® 64 (x64)
2025-03-11 09:31:39.979 Can use RestartManager to avoid reboot? Yes (0)
2025-03-11 09:31:40.012 Starting the installation process.
2025-03-11 09:31:40.016 Shutting down applications using our files.
2025-03-11 09:31:40.158 Some applications could not be shut down.
2025-03-11 09:31:40.158 Defaulting to Abort for suppressed message box (Abort/Retry/Ignore):
Setup was unable to automatically close all applications. It is recommended that you close all applications using files that need to be updated by Setup before continuing.
2025-03-11 09:31:40.158 User canceled the installation process.
2025-03-11 09:31:40.158 Rolling back changes.
2025-03-11 09:31:40.162 Starting the uninstallation process.
2025-03-11 09:31:40.162 Uninstallation process succeeded.
2025-03-11 09:31:41.676 Deinitializing Setup.
2025-03-11 09:31:41.686 Log closed.
~ ❯ winget install --id REALiX.HWiNFO -e
Found an existing package already installed. Trying to upgrade the installed package...
Found HWiNFO® [REALiX.HWiNFO] Version 8.22
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...
The installer will request to run as administrator, expect a prompt.
Successfully installed
Expected behavior
A successful upgrade on the first try.
Environment
Windows Package Manager v1.10.340
Copyright (c) Microsoft Corporation. All rights reserved.
Windows: Windows.Desktop v10.0.26100.3194
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.25.340.0
Winget Directories
-------------------------------------------------------------------------------------------------------------------------------
Logs %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir
User Settings %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\settings.json
Portable Links Directory (User) %LOCALAPPDATA%\Microsoft\WinGet\Links
Portable Links Directory (Machine) C:\Program Files\WinGet\Links
Portable Package Root (User) %LOCALAPPDATA%\Microsoft\WinGet\Packages
Portable Package Root C:\Program Files\WinGet\Packages
Portable Package Root (x86) C:\Program Files (x86)\WinGet\Packages
Installer Downloads %USERPROFILE%\Downloads
Configuration Modules %LOCALAPPDATA%\Microsoft\WinGet\Configuration\Modules
Links
---------------------------------------------------------------------------
Privacy Statement https://aka.ms/winget-privacy
License Agreement https://aka.ms/winget-license
Third Party Notices https://aka.ms/winget-3rdPartyNotice
Homepage https://aka.ms/winget
Windows Store Terms https://www.microsoft.com/en-us/storedocs/terms-of-sale
Admin Setting State
--------------------------------------------------
LocalManifestFiles Enabled
BypassCertificatePinningForMicrosoftStore Disabled
InstallerHashOverride Disabled
LocalArchiveMalwareScanOverride Disabled
ProxyCommandLineOptions Disabled
DefaultProxy Disabled
Screenshots and Logs
I pasted the relevant console output and log file above.
Perhaps some command line parameters passed to the installer could make it more persistent at closing the running HWiNFO instance so this error doesn't ever occur? Both /CLOSEAPPLICATIONS and /FORCECLOSEAPPLICATIONS are available, but I'm assuming the /CLOSEAPPLICATIONS parameter is already on.
Another option might be to run a pre-install script to close HWiNFO and maybe give a more helpful error message if HWiNFO refuses to close for some reason.