-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
winget upgrade --all aways tries to upgrade vscode #976
Comments
@LuanVSO this is primarily related to the version numbers in the manifest with a four part identifier and the entry in Add/Remove Programs having a three part identifier. I moved this Issue to the client to see if this might be something generic we need to consider in the client when we do our comparisons for tracking what version of a package we installed vs. what we see in Add/Remove programs. This could likely be addressed by modifying the "PackageVersion" in the manifest, but I want to give the Visual Studio Code team an opportunity to evaluate before changing their manifests. |
@OfficialEsco, We use alpha sort on each token in the version string. If the 21.02 alpha is updated to 21.02-alpha it should work. |
I have encountered a similar case with Anvil Studio:
The official version string is 2020.12.03 which is also what's in the manifest but the version in Add/Remove programs is 20.12.03. Changing the version format in the manifest accordingly is no long-term solution, I think, as somebody else might change it again with an update, breaking it. Maybe an alternative version field could help in the manifest with the format to use to correlate entries in Add/Remove Programs. |
I think some of these issues could potentially be detected automatically in CI during manifest validation. After installing a program, it could be checked whether the installer added an entry to Add/Remove Programs with a version number that matches the one in the manifest, and if not require the version to be adapted or require the specification of an alternative version field. |
@chausner, that's a great idea! You mind creating that as a Feature Request/Idea in the winget-pkgs repository? |
I created microsoft/winget-pkgs#13620 and https://github.com/microsoft/winget-pkgs/issues/13622. |
@denelon i renamed the 7ZipAlpha manifest #13613 and its still upgrading to 21.01-alpha Can it be because 21.01 is installed as exe? Edit: |
@lszomoru Is there a particular reason the four part identifier is used at all for VSCode? In release notes they only ever use the three part one. I can understand for Insiders (since you want to tie it back to the commit in microsoft/code), but not for stable. |
@OfficialEsco we do try to ensure to use the same "InstallerType" used previously. We're running into a similar challenge with PowerToys as it is an .msi file inside of a .exe that performs bootstrapping work. |
I know I said this somewhere else, but once we get dependency support, we should see if the PowerToys team would be willing to supply a standalone MSI for WinGet so we can upgrade it the usual way. I need to open an issue about that when I have a second... |
@psychelzh I've seen a few installers that support "side by side" install for different versions. I'm wondering if a previous call to upgrade actually "upgraded" more than one of them. Could you submit feedback ([Windows]+[f] - "Apps" & "Windows Package Manager") and share the link here so we can look at logs? |
@denelon Is it this: https://aka.ms/AAco74f |
Some other apps. Most of them from MS, and maybe 10+ apps from another vendors was successfully updated: Mozilla.FirefoxDeveloperEdition -it was updated to latest version, but i still have it in upgrade command Logs:
|
as on topic of VSC I can repro it. steps: |
@Karl-WE These issues mainly comes from Bots updating Packages with weird/inconsistent version number in the download link/after install... I see you've struggled with 7-Zip too, which comes from us replacing the EXE installer with the MSI installer (since people here would prefer a MSI install), however @denelon explained in this thread that WinGet will try to use the same InstallerType, so for future manifests we will have to add the MSI as Primary and the EXE as Secondary so the upgrade works.. |
Makes sense thank you @OfficialEsco |
I have a similar issue with the NVAccess.NVDA package, though it incists on downgrading. I have version 'alpha-22934,e05715d3' installed whereas winget tries to upgrade (or rather downgrade) to version 2020.4, which is the most recent version. See also nvaccess/nvda#12469 |
I see multiple issues myself, see here:
|
@OfficialEsco Thank you, that fixes most of the issues, I still have VS Code and VS Pro reinstalling, will try to understand why later. |
In shorter words: the Visual Studio Team needs to fix their stuff |
I've proposed a solution in #1073. For Visual Studio specifically, it will need some refinement (or for the VS team to rearchitect their installer to act right) but for other programs this would help I think. |
I have made the necessary changes to the pipeline that publishes the Visual Studio Code winget package. We have dropped the 4th segment of the version number, so now the version in the winget manifest matches the version number in add/remote programs. @denelon, can you please go ahead and close the issue as I do not seem to have the necessary permissions. Thanks! |
@lszomoru thank you for making the changes! |
Brief description of your issue
Winget always sees vscode as if it is not up-to-date. i think it is because the version number on the manifest includes the commit id, but the version reported back from
Winget list
doesn't.Steps to reproduce
Expected behavior
Winget should detect that the most recent version of vscode is already installed
Actual behavior
it thinks there's a new update for vscode
Environment
Recommended fix
just remove the commit id from the version number in the manifest
The text was updated successfully, but these errors were encountered: