microsoft / microsoft/winget-cli

Random assertion failure on `winget upgrade`

Open
#3,771 12 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Command-Upgrade 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

I randomly (and, alas, non-reproducibly) get the following error after winget upgrade has (apparently) correctly applied an update:

[6/6] Upgrading 'VLC media player' (Id='VideoLAN.VLC') from version '3.0.18' to version '3.0.19' via 'winget upgrade --id VideoLAN.VLC --version 3.0.19'
Found VLC media player [VideoLAN.VLC] Version 3.0.19
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://download.videolan.org/videolan/vlc/3.0.19/win64/vlc-3.0.19-win64.msi
  ██████████████████████████████  56.2 MB / 56.2 MB
Successfully verified installer hash
Starting package install...
An unexpected error occurred while executing the command:
0x8007029c : An assertion failure has occurred.
winget exit code: 0x8007029c
Steps to reproduce

This occurs upon execution of winget upgrade but there's no actual repro scenario.

Expected behavior

winget upgrade should not display an assertion message, and exit with exit code 0.

Actual behavior
An unexpected error occurred while executing the command:
0x8007029c : An assertion failure has occurred.
Environment
Windows Package Manager v1.6.2771
Copyright (c) Microsoft Corporation. All rights reserved.

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

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 execution described in the report and inspect diagnostic output in %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir. Because the failure is intermittent and has no reproduction scenario, determine which upgrade path emits 0x8007029c; done means a successful update exits with code 0 without the assertion message.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.