microsoft / winget-pkgs

The Microsoft community Windows Package Manager manifest repository
MIT License
8.31k stars 4.25k forks source link

[Package Issue]: Microsoft.PowerShell #100108

Open simkoG opened 1 year ago

simkoG commented 1 year ago

Please confirm these before moving forward

Category of the issue

Other

Brief description of your issue

After updating Microsoft.PowerShell to the latest version (v7.3.3), winget still shows that an update is available for the app (even after Terminal relaunch).

Steps to reproduce

1) Install Microsoft.PowerShell 7.3.2.0. 2) Run winget upgrade Microsoft.PowerShell. 3) The app will be updated. 4) Close the Terminal app. 5) Run winget list Microsoft.PowerShell. 6) See that the version remains 7.3.2.0.

Actual behavior

Do not try to update Microsoft.PowerShell after updating it.

Expected behavior

The app gets updated but the version number will be the old one within winget package manager.

Environment

> winget --info
Windows Package Manager v1.4.10173
Copyright (c) Microsoft Corporation. All rights reserved.

Windows: Windows.Desktop v10.0.19045.2728
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.19.10173.0

Logs: %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir

User Settings: %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\settings.json

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

Screenshots and Logs

image

stephengillie commented 1 year ago

The "upgrade always available" situation is sometimes caused by registry entries from previous installations. Is there another PowerShell entry in Apps and Features?

R-Adrian commented 1 year ago

terminal relaunch or not... did you install the powershell upgrade while still in a powershell terminal? did you reboot afterterwards?

Powershell is a system-wide application, a simple terminal relaunch will not cause the executable to be replaced by the windows installer - that usually happens on reboot if the installer finds the exe file was in use at the time of the installation.

simkoG commented 1 year ago

@R-Adrian Yes, a system reboot will fix the issue.

BrandonWanHuanSheng commented 1 year ago

It look like cmd don't have but in the terminal have. Most likely, windows reboot will take affect the registry. Sometimes, you will noticed windows is working on their cumulative update.