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

Unable to Add Pin; Trying to upgrade the installed package... #4249

Closed
dgulik opened this issue Mar 7, 2024 · 2 comments
Closed

Unable to Add Pin; Trying to upgrade the installed package... #4249

dgulik opened this issue Mar 7, 2024 · 2 comments
Milestone

Comments

@dgulik
Copy link

dgulik commented Mar 7, 2024

Brief description of your issue

Unable to pin a package. The package was previously pinned. After having some other issues with winget, I reset it and then ran upgrade all and it started to upgrade a previously pinned package, and I closed the CLI while this upgrade was in progress. Now I am unable to pin this package. Please, refer to screenshot.
Screenshot 2024-03-06 201649
image

Steps to reproduce

winget add pin OBSProject.OBSStudio
winget add pin WavesAudio.WavesCentral

both of these were previously pinned.

Expected behavior

packages to be pinned so I can run upgrade --all

Actual behavior

packages are not pinning due to error; "Trying to upgrade the installed package..."

Environment

Windows Package Manager v1.7.10582
Copyright (c) Microsoft Corporation. All rights reserved.

Windows: Windows.Desktop v10.0.22631.3235
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.22.10582.0
@microsoft-github-policy-service microsoft-github-policy-service bot added the Needs-Triage Issue need to be triaged label Mar 7, 2024
@Trenly
Copy link
Contributor

Trenly commented Mar 7, 2024

@dgulik - Have you tried winget pin add instead of winget add pin? winget add is an alias for winget install

PS D:\Git\winget-pkgs> winget install -?
Windows Package Manager v1.7.10582
Copyright (c) Microsoft Corporation. All rights reserved.

Installs the selected package, either found by searching a configured source or directly from a manifest. By default, the query must case-insensitively match the id, name, or moniker of the package. Other fields can be used by passing their appropriate option. By default, install command will check package installed status and try to perform an upgrade if applicable. Override with --force to perform a direct install.

usage: winget install [[-q] <query>...] [<options>]

The following command aliases are available:
  add

https://learn.microsoft.com/en-us/windows/package-manager/winget/pinning#usage

PS D:\Git\winget-pkgs> winget pin -?
Windows Package Manager v1.7.10582
Copyright (c) Microsoft Corporation. All rights reserved.

Manage package pins with the sub-commands. A pin can limit the Windows Package Manager from upgrading a package to specific ranges of versions, or it can prevent it from upgrading the package altogether. A pinned package may still upgrade on its own and be upgraded from outside the Windows Package Manager.

usage: winget pin [<command>] [<options>]

The following sub-commands are available:
  add     Add a new pin
  remove  Remove a package pin
  list    List current pins
  reset   Reset pins

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs-Author-Feedback Issue needs attention from issue or PR author and removed Needs-Triage Issue need to be triaged labels Mar 7, 2024
@dgulik
Copy link
Author

dgulik commented Mar 7, 2024 via email

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs-Attention Issue needs attention from Microsoft and removed Needs-Author-Feedback Issue needs attention from issue or PR author labels Mar 7, 2024
@dgulik dgulik closed this as completed Mar 7, 2024
@microsoft-github-policy-service microsoft-github-policy-service bot removed the Needs-Attention Issue needs attention from Microsoft label Mar 7, 2024
@denelon denelon added this to the 1.8 Client milestone May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants