microsoft / microsoft/winget-cli

Installation fails with no output message

Open
#4,692 8 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Issue-Bug
Dominant language
C++
Stars
26.4k
Forks
1.8k
Avg merge
1d 11h
Merged PRs (30d)
15

Description

Brief description of your issue

Winget will respond normally to many commands, but refuses to do any installations. Anytime I wrote, for example, winget upgrade --all, it would simply display a spinner for a bit, and then exit with no error message.

Logs

I checked the logs, which look like this:

2024-07-31 09:15:59.151 [CORE] WinGet, version [1.8.1911], activity [{EAE8B4B6-154D-42E2-AA82-50B6F9F43277}]
2024-07-31 09:15:59.151 [CORE] OS: Windows.Desktop v10.0.22631.3958
2024-07-31 09:15:59.151 [CORE] Command line Args: "C:\Program Files\WindowsApps\Microsoft.DesktopAppInstaller_1.23.1911.0_x64__8wekyb3d8bbwe\WindowsPackageManagerServer.exe" -Embedding
2024-07-31 09:15:59.151 [CORE] Package: Microsoft.DesktopAppInstaller v1.23.1911.0
2024-07-31 09:15:59.151 [CORE] IsCOMCall:1; Caller: C:\Windows\explorer.exe
2024-07-31 09:15:59.163 [CORE] Default proxy is not set
2024-07-31 09:15:59.163 [REPO] REST HTTP Client helper does not use proxy
2024-07-31 09:15:59.171 [REPO] REST HTTP Client helper does not use proxy
2024-07-31 09:15:59.177 [REPO] Sending http GET request to: https://storeedgefd.dsx.mp.microsoft.com/v9.0/information
2024-07-31 09:15:59.307 [REPO] Response status: 200
2024-07-31 09:15:59.307 [REPO] Authentication node not found. Assuming authentication type none.
2024-07-31 09:15:59.307 [REPO] Sending http GET request to: https://storeedgefd.dsx.mp.microsoft.com/v9.0/information
2024-07-31 09:15:59.325 [REPO] Response status: 200
2024-07-31 09:15:59.325 [REPO] Authentication node not found. Assuming authentication type none.
2024-07-31 09:15:59.328 [REPO] Creating new SQLite Index with version [Latest] at ':memory:'
2024-07-31 09:15:59.364 [REPO] Reading MSI UpgradeCodes
2024-07-31 09:15:59.600 [REPO] Reading MSI UpgradeCodes
2024-07-31 09:16:00.089 [REPO] Opening database for ReadWrite at 'C:\Users\chhou\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\StoreEdgeFD\installed.db'
2024-07-31 09:16:00.090 [REPO] Opened SQLite Index with version [1.3], last write [2022-05-24 11:15:13.000]
2024-07-31 09:16:00.117 [REPO] Sending http POST request to: https://storeedgefd.dsx.mp.microsoft.com/v9.0/manifestSearch
2024-07-31 09:16:00.137 [REPO] Response status: 200
2024-07-31 09:16:00.191 [REPO] Opening database for ReadWrite at 'C:\Users\chhou\AppData\Local\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\Microsoft.Winget.Source_8wekyb3d8bbwe\installed.db'
2024-07-31 09:16:00.192 [REPO] Opened SQLite Index with version [1.3], last write [2024-07-04 15:39:58.000]

However, sometimes the following line will appear at the bottom:

2024-07-31 09:16:49.294 [REPO] Did not find Id [calibre.calibre] in tracked source: winget

I was able to successfully examine the SQLite database file, and nothing stood out as missing or wrong at a glance.
I also checked the other directories in %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\, but found nothing notable.

Manual solution

I had previously tried uninstalling and reinstalling before abandoning the issue. That did not work. I even tried reinstalling App Installer.
This time, I decided to just rename the entire %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe to %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.bak. When I tried to re-run winget upgrade --all, everything finally worked. I still have the backup if you need additional information.

Steps to reproduce

I do not know how my winget got into the state it was in for the bug to appear. I haven't manually modified any of its files (until I found the solution mentioned above) - at least not intentionally.

Running commands like winget upgrade --all would simply exit with no error message. That is, nothing was printed to the terminal after running the command.

Expected behavior

I expect the installer to proceed with upgrading/installing, not simply exit with no message.

Actual behavior

I expect the installer to proceed with upgrading/installing, not simply exit with no message.

Environment
[winget --info]
Windows Package Manager v1.8.1911
Copyright (c) Microsoft Corporation. All rights reserved.

Windows: Windows.Desktop v10.0.22631.3958
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.23.1911.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

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                        Disabled
BypassCertificatePinningForMicrosoftStore Disabled
InstallerHashOverride                     Disabled
LocalArchiveMalwareScanOverride           Disabled
ProxyCommandLineOptions                   Disabled
DefaultProxy                              Disabled

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the winget upgrade --all path and the App Installer package-state directories named in the report, using the supplied logs and backup to investigate the silent exit. There is no source file, failing test, or reliable reproduction identified; done would mean reproducing the failure and establishing a user-visible error or a confirmed installation path.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, sqlite
Domain
cli, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.