Repository navigation
Closed
Labels
Area-ExternalIssue outside of winget-cli sourceArea-MatchingIssue related to correlation between installed package and manifestCommand-UninstallIssue related to WinGet UninstallIssue-BugIt either shouldn't be doing this or needs an investigation.Side-by-SideIssue related to side by side package installation
Milestone
Description
Brief description of your issue
Powerwell won't update, and tells me to uninstall existing version. But when I try to uninstall I get an error.
Steps to reproduce
❯ winget list --name Microsoft.Powershell
No installed package found matching input criteria.
❯ winget uninstall --name Microsoft.Powershell
No installed package found matching input criteria.
Expected behavior
I expect to see that powershell is installed and which version. And I expect to then be able to uninstall it.
Actual behavior
Oh dear. What can i say, it's behaving like a hello-world app that just prints out error messages. I'm yet to see winget actually do anything.
Environment
Windows Package Manager v1.6.3482
Copyright (c) Microsoft Corporation. All rights reserved.
Windows: Windows.Desktop v10.0.22631.3085
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.21.3482.0
Winget Directories
-----------------------------------------------------------------------------------------------------------------------
Logs %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\Diag…
User Settings %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\sett…
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 DisabledMetadata
Metadata
Assignees
Labels
Area-ExternalIssue outside of winget-cli sourceArea-MatchingIssue related to correlation between installed package and manifestCommand-UninstallIssue related to WinGet UninstallIssue-BugIt either shouldn't be doing this or needs an investigation.Side-by-SideIssue related to side by side package installation
Activity
[-]Can uninstall Powershell[/-][+]Can't uninstall Powershell[/+]mdanish-kh commentedon Feb 5, 2024
--namefilters packages based on theDisplayNamestring value they write to Registry. That's the name of the package visible in Control Panel / Apps&Features.Microsoft.PowerShellis the unique identifier given to the package in the winget repository, so--idis the filter you're looking for here.You may find more value in just
winget list powershellsince that forces the match on many different parameters listed in the manifest (substring match on ID, name, tags, commands etc..).However, looking at another issue you raised (#4139), I'm guessing you want to unblock the
winget install/upgrade Microsoft.PowerShellcommand. The output ofwinget list powershellon your machine would give me more context, but I'm assuming you have a side-by-side installation of PowerShell MSIX (installed from MS store) and PowerShell MSI (can be installed through their github releases / through winget). WinGet currently can't reason correctly about side-by-side installations (see #2129). It maps both of the installations to the same PackageId (Microsoft.PowerShell), and gets confused as to which installer type to update. You can either use--forceto force winget to bypass the check, or provide exact matching by the DisplayName (since PowerShell MSI and PowerShell MSIX use a different name in Apps&Features).TLDR
Use either one of these commands:
winget upgrade Microsoft.PowerShell --forcewinget upgrade --name "PowerShell 7-x64"(if you have the 64-bit version)to bypass the installer type check
denelon commentedon Apr 2, 2024
We've been working on the side-by-side scenarios. You could try the latest release and enable the experimental feature on:
Please provide feedback at: