Skip to content
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

Can't upgrade a package whose version number is unknown #2714

Closed
yume-chan opened this issue Nov 22, 2022 · 4 comments · Fixed by #2747
Closed

Can't upgrade a package whose version number is unknown #2714

yume-chan opened this issue Nov 22, 2022 · 4 comments · Fixed by #2747
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation.
Milestone

Comments

@yume-chan
Copy link

Brief description of your issue

winget list -s winget shows I have rustup installed but the version number is unknown (because it was installed manually, not from winget)

> winget list -s winget --id Rustlang.Rustup
Name                                 Id              Version Available
----------------------------------------------------------------------
Rustup: the Rust toolchain installer Rustlang.Rustup Unknown 1.25.1

But when I try to upgrade it via winget upgrade --id Rustlang.Rustup -s winget, it shows this error:

> winget upgrade --id Rustlang.Rustup -s winget
This package's version number cannot be determined. To upgrade it anyway, add the argument --include-unknown to your previous command.

So I did what it says, but it still doesn't work

> winget upgrade --id Rustlang.Rustup -s winget --include-unknown
Windows Package Manager (Preview) v1.4.3132-preview
Copyright (c) Microsoft Corporation. All rights reserved.

Incompatible command line arguments provided

I also tried the install command instead:

> winget install Rustlang.Rustup -s winget
Failed in attempting to update the source: winget
Found an existing package already installed. Trying to upgrade the installed package...
This package's version number cannot be determined. To upgrade it anyway, add the argument --include-unknown to your previous command.

> winget install Rustlang.Rustup -s winget --include-unknown
Windows Package Manager (Preview) v1.4.3132-preview
Copyright (c) Microsoft Corporation. All rights reserved.

Argument name was not recognized for the current command : '--include-unknown'

Steps to reproduce

  1. Run winget upgrade --id Rustlang.Rustup -s winget --include-unknown

Expected behavior

It upgrades (reinstalls) the package from winget.

Actual behavior

It outputs Incompatible command line arguments provided

Environment

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

Windows: Windows.Desktop v10.0.25247.1000
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.19.3132.0

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

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
@ghost ghost added the Needs-Triage Issue need to be triaged label Nov 22, 2022
@denelon denelon added Issue-Bug It either shouldn't be doing this or needs an investigation. and removed Needs-Triage Issue need to be triaged labels Nov 22, 2022
@denelon denelon added this to the v1.4-Client milestone Nov 22, 2022
@denelon
Copy link
Contributor

denelon commented Nov 22, 2022

I'm not sure if this is due to some of the other arguments.

Can you try winget upgrade Rustlang.Rustup --include-unknown?

@denelon denelon added the Needs-Author-Feedback Issue needs attention from issue or PR author label Nov 22, 2022
@denelon
Copy link
Contributor

denelon commented Nov 22, 2022

It would also help if you could share logs.

@yume-chan
Copy link
Author

> winget upgrade Rustlang.Rustup --include-unknown --verbose
Windows Package Manager (Preview) v1.4.3132-preview
Copyright (c) Microsoft Corporation. All rights reserved.

Incompatible command line arguments provided

Log:

2022-11-23 15:55:24.046 [CORE] WinGet, version [1.4.3132-preview], activity [{C2EE26E5-66CC-4541-9FD3-FBEE2291D23B}]
2022-11-23 15:55:24.047 [CORE] OS: Windows.Desktop v10.0.25247.1000
2022-11-23 15:55:24.047 [CORE] Command line Args: "C:\Users\simon\AppData\Local\Microsoft\WindowsApps\winget.exe" upgrade Rustlang.Rustup --include-unknown --verbose
2022-11-23 15:55:24.047 [CORE] Package: Microsoft.DesktopAppInstaller v1.19.3132.0
2022-11-23 15:55:24.047 [CORE] IsCOMCall:0; Caller: winget-cli
2022-11-23 15:55:24.050 [CLI ] WinGet invoked with arguments: 'upgrade' 'Rustlang.Rustup' '--include-unknown' '--verbose'
2022-11-23 15:55:24.050 [CLI ] Found subcommand: upgrade
2022-11-23 15:55:24.050 [CLI ] Leaf command to execute: root:upgrade
2022-11-23 15:55:24.055 [CORE] Setting action: Get, Type: Secure, Name: admin_settings
2022-11-23 15:55:24.055 [CORE] Admin settings was not found
2022-11-23 15:55:24.073 [CLI ] Error encountered parsing command line: Incompatible command line arguments provided

@ghost ghost added Needs-Attention Issue needs attention from Microsoft and removed Needs-Author-Feedback Issue needs attention from issue or PR author labels Nov 23, 2022
@MikeCardiff
Copy link

I'm also having the same issue.

Commands

> winget upgrade ShiningLight.OpenSSL.Light
This package's version number cannot be determined. To upgrade it anyway, add the argument --include-unknown to your previous command.

> winget upgrade ShiningLight.OpenSSL.Light --include-unknown
Windows Package Manager (Preview) v1.4.3132-preview
Copyright (c) Microsoft Corporation. All rights reserved.

Incompatible command line arguments provided

Logs

2022-11-30 19:09:31.970 [CORE] WinGet, version [1.4.3132-preview], activity [{624A4340-D8EC-49C9-B708-4003A42B5878}]
2022-11-30 19:09:31.971 [CORE] OS: Windows.Desktop v10.0.22621.819
2022-11-30 19:09:31.971 [CORE] Command line Args: "C:\Users\Name\AppData\Local\Microsoft\WindowsApps\winget.exe" upgrade ShiningLight.OpenSSL.Light --include-unknown
2022-11-30 19:09:31.971 [CORE] Package: Microsoft.DesktopAppInstaller v1.19.3132.0
2022-11-30 19:09:31.971 [CORE] IsCOMCall:0; Caller: winget-cli
2022-11-30 19:09:31.975 [CLI ] WinGet invoked with arguments: 'upgrade' 'ShiningLight.OpenSSL.Light' '--include-unknown'
2022-11-30 19:09:31.975 [CLI ] Found subcommand: upgrade
2022-11-30 19:09:31.975 [CLI ] Leaf command to execute: root:upgrade
2022-11-30 19:09:31.993 [CLI ] Error encountered parsing command line: Incompatible command line arguments provided

@ghost ghost added the In-PR Issue related to a PR label Dec 6, 2022
@ghost ghost added Resolution-Fix-Committed and removed In-PR Issue related to a PR labels Dec 6, 2022
@denelon denelon removed the Needs-Attention Issue needs attention from Microsoft label Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants