microsoft / microsoft/winget-cli

Fix software update when old MSI installer is missing (MSI exit code 1603)

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

Nobody has claimed this yet.

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

Description

Brief description of your issue

Upgrading a software package should only require the installer of the new version but unfortunately, the old installer is also essential to be present. If it is not, automated installation fails. (In case of an interactive installation, a modal window pops up that allows you to point to it.)

As the process of upgrading breaks down unexpectedly, I classify this failure as a bug. Technically, though, fixing it will require some new code to be added rather than fixing some existing code, so you may also consider it a borderline feature request.

For further details, see UniGetUI issue 2742 whence I was redirected here. As that software simply calls winget, the issue described there can be simply understood in terms of this software. Also see the first comment and my answer to it there.

Steps to reproduce
  1. winget install <any software with an MSI installer mechanism such as LibreOffice 24.8.0>
  2. Wait for a bit for a newer version to appear. (Or install an old version to begin with in the previous step.)
  3. Make sure that the old .msi installer file is not present at its old location. (In an actual system, cleanups will remove such files.)
  4. Using winget, attempt upgrading to a newer version of LibreOffice, say 24.8.1.
Expected behavior
  1. Without prompting the user or stopping the upgrade, winget figures out that a deprecated version's .msi installer file for the package is required but missing, and downloads it.
    • Obviously, deal with corner cases such as not enough space.
  2. The old version is uninstalled without any hiccups, then the new version is installed.
  3. Housekeeping: the downloaded file is deleted.
Actual behavior

MSI Installer exit code 1603.

For further details, see UniGetUI issue 2742.

Environment
Windows Package Manager v1.8.1911
Windows: Windows.Desktop v10.0.22631.4169
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.23.1911.0

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 by reproducing the upgrade using winget with an MSI-based package such as LibreOffice, ensuring the previous .msi is absent. Trace the MSI upgrade path responsible for exit code 1603 and determine how a missing legacy installer could be obtained and cleaned up; done means the upgrade completes without prompting and the temporary download is removed.

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
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.