Skip to content

unexpected behaviour - Installation abandoned #713

Description

Brief description of your issue

upgrading PowerShell might take longer as expected. Winget causes to terminate with "Installation abandoned"

Steps to reproduce

  1. Have a previous version of PowerShell 7 installed, e.g. 7.1.0
  2. winget install powershell to upgrade to the latest version
  3. watch the output

Expected behavior

Winget should wait for the msi processes to end and check logs for exit / error codes

Actual behavior

winget is prematurely exiting with "Installation abandoned" while the uninstall / installation is still running and was overly successful.

image

Logs

MSI (s) (54:48) [10:46:37:555]: Product: PowerShell 7-x64 -- Installation completed successfully.

MSI (s) (54:48) [10:46:37:556]: Das Produkt wurde durch Windows Installer installiert. Produktname: PowerShell 7-x64. Produktversion: 7.1.1.0. Produktsprache: 1033. Hersteller: Microsoft Corporation. Erfolg- bzw. Fehlerstatus der Installation: 0.
WinGet-2021-1-22-10-44-54.016.log
WinGet-Microsoft.PowerShell.7.1.1-2021-1-22-10-45-17.287.log

Environment

Win10 Insider Dev
Powershell 7

Windows Package Manager v0.2.3162 Vorschau
Copyright (c) Microsoft Corporation. Alle Rechte vorbehalten.

Windows: Windows.Desktop v10.0.21296.1000
Paket: Microsoft.DesktopAppInstaller v1.11.3162.0

Any other software?
nothing specific.
AV: Windows Defender
System protection turned off

Activity

  1. ghost added
    Needs-TriageIssue needs to be triaged
    on Jan 23, 2021
  2. added
    Issue-BugIt either shouldn't be doing this or needs an investigation.
    and removed
    Needs-TriageIssue needs to be triaged
    on Jan 25, 2021
  3. denelon commented on Jan 25, 2021

    @denelon
    Collaborator

    We see this when the shell we're executing in resets itself. We are looking at solutions.

  4. Karl-WE commented on Jan 26, 2021

    @Karl-WE
    ContributorAuthor

    Thanks for this info Demetrius!

  5. denelon commented on Apr 29, 2021

    @denelon
    Collaborator

    We will need to add another key to manifests indicating the installation or upgrade of this application could cause a "restart" of your shell/terminal. MSIX has a delayed registration process that could also be triggered with this same key.

    I'm converting this "Bug" into a "Feature" to capture this request.

  6. added
    Issue-FeatureThis is a feature request for the Windows Package Manager client.
    Area-ManifestThis may require a change to the manifest
    and removed
    Issue-BugIt either shouldn't be doing this or needs an investigation.
    on Apr 29, 2021
  7. denelon commented on Jul 1, 2021

    @denelon
    Collaborator

    We could offer a message like:
    "Installer known to restart shell or terminal. The install may succeed unless you aborted the installation."

    The descriptive text for the key could be:
    "This installer sends abort signal ([Ctrl]+[c]) to current terminal."

    How about:

    Installers:
      - Architecture: x64
        InstallerUrl: https://github.com/PowerShell/PowerShell/releases/download/v7.1.3/PowerShell-7.1.3-win-x64.msi
        InstallerType: msi
        InstallerSha256: 459642D8B6D69F643794DF8394F28191F43E5ED35472899C4F0D8424F6D1317C
        InstallerAbortsTerminal: true
  8. added this to the milestone on Jul 1, 2021
  9. denelon commented on Oct 1, 2021

    @denelon
    Collaborator

    "InstallerAbortsTerminal": {
    "type": [ "boolean", "null" ],
    "description": "Indicates whether the installer will abort terminal. Default is false"
    },

  10. modified the milestones: , v1.3-Client on Dec 1, 2021
  11. ghost added
    In-PRIssue related to a PR
    on Aug 5, 2022
  12. ghost removed
    In-PRIssue related to a PR
    on Aug 12, 2022
  13. omostan commented on Mar 17, 2026

    @omostan

    In my case, the upgrade from version 7.5.4 to 7.5.5 was successful even though I got the message "Installation abandoned". After restarting the terminal, the new version was just fine.

    The solution to this misinformation is simple, just change the message to something like "Restart the terminal to complete the installation". This issue have been reported long time ago and it's time to stop the confusion.

  14. Karl-WE commented on Mar 27, 2026

    @Karl-WE
    ContributorAuthor

    My experience was bit different. Same error message but effectively after restart of terminal it was still on the previous version.

    Only winget install Microsoft.PowerShell fixed it.

    Logs:
    https://1drv.ms/f/c/cf2986dfddddf194/IgAl6aJziAvAQY9oltnzd_XBAV7OQMu_o9BTalOU-z1ly8U

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area-ManifestThis may require a change to the manifestIssue-FeatureThis is a feature request for the Windows Package Manager client.

    Type

    No type

    Projects

    • Status
      Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions