-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Number/list of updates available totally broken, update
not working
#3356
Comments
@aetonsi thanks for the detailed feedback. Lots to unpack here. I'll see about referencing the existing issues to help split this into the separate classes of issues to make sure we're tracking everything.
The other reason one might see "Unknown" is in the available column. This is treated as a "sentinel value" so WinGet doesn't try to upgrade to an unknown version. Currently, the Microsoft Store "msstore" REST source doesn't expose the version information, so all packages report unknown. We are working on getting this metadata updated. It's a very long lead time work item due to the way the data is captured, stored, and presented. |
By coincidence, I was chatting with @Trenly this morning and he shared his tracking list which makes the rest of the breakdown a bit easier: The PowerShell issue is matching/side-by-side: Upgrade all not upgrading all is labeled with "Area-Output": Upgrade by Id works for me, but this depends on which version of the installer was used for the currently installed version. Update with wrong count of unknown is correctly identified as: Register available version is: |
I don't believe I saw any untracked issues in your report. Please check to make sure I've not missed anything. We use the sort by👍in Issues to prioritize in addition to: Be sure to add your 👍 to any Issues to help raise priority. I'm going to mark the issue as "Needs-Author-Feedback" before closing it, so you have a chance to confirm nothing was missed. |
This comment has been minimized.
This comment has been minimized.
Hi, sorry for the late reply. What about the line about packages with "version numbers that cannot be determined" being printed twice? I mean the last 2 lines here:
Also, i don't understand the following:
Do you mean the version of the Microsoft Visual Studio Installer? It's
|
Some applications have multiple different installer types - exe, msi, zip, portable, etc. |
How can i check the actual version of the installer, so i can tell you which one is it? |
Is there a way i can "fix" this, so that the update works, without having to do a full reinstallation? |
I'm not sure if this solution is appropriate for this thread, but I've encountered a similar issue. When executing
To address this issue, I created a PowerShell script (.ps1) that automates the update process for all packages without needing to specify them manually. The script collects the IDs of the packages and updates them one by one. The code is as follows: write-host "Updating winget upgrade list..."
$OUTPUT=winget.exe upgrade
Write-Host "Filtering list..."
$regexPattern = '([a-zA-Z-]+(?:\.[a-zA-Z0-9]+)+)'
$match = [regex]::Matches($OUTPUT, $regexPattern)
$packageNames = $match | ForEach-Object { $_.Value.Trim() }
Write-Host $packageNames
$LIST = $packageNames.Split(" ")
Write-Host "Excluding packages..."
Write-Host $LIST
Write-Host "*********"
for ($i = 0; $i -lt $LIST.count; $i++) {
write-host "$i/$($LIST.count). Upgrading $($LIST[$i])..."
winget.exe upgrade --id "$($LIST[$i])"
} This script starts by displaying the list of packages to be updated, filters and excludes packages as needed, and finally, updates each one using its corresponding ID. |
Is this still happening in WinGet 1.8? |
yes. i'm on
|
@aetonsi Could you run the command |
sorry i already updated protondrive within the protondrive UI itself.. looking into the logs folder if you want i found this older log of a
|
That's okay. The log that you shared doesn't seem to offer all that much context other than failing with |
Brief description of your issue
Hi, i found a few problems with the
update
command, but i'm not even sure if these are all of them, so please see the log at the end that might be clearer than my explanations/suppositions.When running
update
commands, to list available updates or to update packages, a number of problems occur:update --all --include-unknown
tries to update 3 out of 6 listed packages. More details:update --all
norupdate --id ...
, the update commands simply skips them and reports "no applicable update found"; in reality, visual studio's already installed version is 17.6.2 (so an update should be available) and powershell version is 7.3.4 (so the lastest version is already installed)--include-unknown
update --all --include-unknown
, meaning each one of them gets installed successfully, but still end up with "unknown" version after installation (idk maybe this is the expected behaviour?), so they are perpetually listed as having an update availableupdate --all
command reports twice the line "X packages have version numbers that cannot be determined. Use --include-unknown to see all results", the second time with a totally random numberI don't even know if these problems are related to each other, of if i should open a separate issue for some/all of them. Please notice me if i should do that.
Also please rename the issue if a better title could be found.
Steps to reproduce
i don't know, aside running the commands below, while having the following software installed:
Expected behavior
update
should report the correct versions (powershell is wrong, 7.3.4 is already installed)update --all [--include-unknown]
should update every package, not skipping over any one of them (powershell, visual studio, windirstat)update --id ...
should work, but i think this is probably issue Uninstallation:No installed package found matching input criteria.
(--name/--id behaviour) #3093update --all
should not report a wrong number of packages with unknown version numbers, and especially should not report it twice; maybe this is --include-unknown shows a lower number of packages after running "winget upgrade --all" #2458 ?update --all --include-unknown
should register the "available version" as the "installed version" for packages that have unknown version number and get updated successfully; having them all repeatedly updated each time i run that command, is annoying (also because some updates take a very long time, for example the google cloud sdk takes over 5 minutes on my machine). Of the 6 updates that are listed as available on my pc, everything is already up to date except visual studio community, which is even skipped for some reasonActual behavior
Environment
The text was updated successfully, but these errors were encountered: