microsoft / microsoft/winget-cli
Terminal error message: Access denied
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 26.4k
- Forks
- 1.8k
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 15
Description
Brief description of your issue
I know this bug has been posted in issues before this, but I still haven't solved my problem after scrutinizing those issues, and my winget still doesn't work, so I'm reopening a new issue, so I hope you guys can understand me.
My current version of winget is "1.21.3482.0", which is the latest version of winget, and I have manually added "%userprofile%\AppData\Local\Microsoft\WindowsApps" to my system environment variables. But I can't use any commands of winget in terminal, it will tell me that access is denied.
My Windows version information is as follows:
Version: Windows 11 Professional
Version: 23H2
OS version: 22631.3227
Experience: Windows Feature Experience Pack 1000.22687.1000.0
Steps to reproduce
$ winget
Expected behavior
I don't know.
Actual behavior
程序“winget.exe”无法运行: 拒绝访问。所在位置 行:1 字符: 1
+ winget
+ ~~~~~~。
所在位置 行:1 字符: 1
+ winget
+ ~~~~~~
+ CategoryInfo : ResourceUnavailable: (:) [], ApplicationFailedException
+ FullyQualifiedErrorId : NativeCommandFailed
Environment
Name : Microsoft.DesktopAppInstaller
Publisher : CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US
Architecture : X64
ResourceId :
Version : 1.21.3482.0
PackageFullName : Microsoft.DesktopAppInstaller_1.21.3482.0_x64__8wekyb3d8bbwe
InstallLocation : C:\Program Files\WindowsApps\Microsoft.DesktopAppInstaller_1.21.3482.0_x64__8wekyb3d8bbwe
IsFramework : False
PackageFamilyName : Microsoft.DesktopAppInstaller_8wekyb3d8bbwe
PublisherId : 8wekyb3d8bbwe
IsResourcePackage : False
IsBundle : False
IsDevelopmentMode : False
NonRemovable : True
Dependencies : {Microsoft.UI.Xaml.2.7_7.2208.15002.0_x64__8wekyb3d8bbwe, Microsoft.VCLibs.140.00.UWPDesktop_14.0.3
3519.0_x64__8wekyb3d8bbwe, Microsoft.DesktopAppInstaller_1.21.3482.0_neutral_split.language-zh-hans
_8wekyb3d8bbwe, Microsoft.DesktopAppInstaller_1.21.3482.0_neutral_split.scale-100_8wekyb3d8bbwe...}
IsPartiallyStaged : False
SignatureKind : Store
Status : Ok
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the winget invocation in PowerShell and the reported Microsoft.DesktopAppInstaller package metadata. Compare the WindowsApps path and environment setup against a working Windows 11 23H2 installation, then determine whether the access-denied behavior can be reproduced. Done means the cause is isolated and a verified remediation or confirmed product defect is documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- cli, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100