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

Microsoft.Windows.Developer/Taskbar fails to hide Widgets button with 'Attempted to perform an unauthorized operation' #67

Open
dmgonch opened this issue Oct 8, 2024 · 0 comments

Comments

@dmgonch
Copy link
Collaborator

dmgonch commented Oct 8, 2024

Brief description of your issue

Recently Microsoft.Windows.Developer/Taskbar DSC resource started failing to hide Windows 11 Widgets button.

Steps to reproduce

On the latest publicly released Windows 11:

  • Right-Click on Windows Taskbar, select Taskbar settings and ensure that Widgets toggle is set to On.
  • Install PowerShell 7 and open it command prompt as administrator
  • To ensure the latest WinGet is installed run Repair-WinGetPackageManager -Latest -Force (potentially some dependencies need to be installed manually by following steps in https://learn.microsoft.com/en-us/windows/package-manager/winget/#install-winget-on-windows-sandbox)
  • Run: Install-Module Microsoft.WinGet.Client -Scope AllUsers -Force and Install-Module Microsoft.WinGet.Configuration -AllowPrerelease -Scope AllUsers -Force
  • Unpack attached repro.dsc.zip to the current folder to get repro.dsc.yaml
  • Run: (Get-WinGetConfiguration -File .\repro.dsc.yaml | Invoke-WinGetConfiguration -AcceptConfigurationAgreements).UnitResults | Format-List

repro.dsc.zip

Expected behavior

No error and Widgets item is turned off

Actual behavior

State                    : Completed
PreviouslyInDesiredState : False
RebootRequired           : False
Type                     : Taskbar
ResultCode               : -1978285818
Message                  : The configuration unit failed while attempting to apply the desired state.
Description              : Attempted to perform an unauthorized operation.
Details                  : at Set, C:\Users\<user>\AppData\Local\Microsoft\WinGet\Configuration\Modules\Microsoft.Windows.Developer\0.2.1\Microsoft.Windows.Developer.psm1: line 330

Environment

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

Windows: Windows.Desktop v10.0.22631.4169
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.23.1911.0

Winget Directories
-------------------------------------------------------------------------------------------------------------------------------
Logs                               %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir
User Settings                      %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\settings.json
Portable Links Directory (User)    %LOCALAPPDATA%\Microsoft\WinGet\Links
Portable Links Directory (Machine) C:\Program Files\WinGet\Links
Portable Package Root (User)       %LOCALAPPDATA%\Microsoft\WinGet\Packages
Portable Package Root              C:\Program Files\WinGet\Packages
Portable Package Root (x86)        C:\Program Files (x86)\WinGet\Packages
Installer Downloads                %USERPROFILE%\Downloads

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

Admin Setting                             State
--------------------------------------------------
LocalManifestFiles                        Disabled
BypassCertificatePinningForMicrosoftStore Disabled
InstallerHashOverride                     Disabled
LocalArchiveMalwareScanOverride           Disabled
ProxyCommandLineOptions                   Disabled
DefaultProxy                              Disabled
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: To Do
Development

No branches or pull requests

2 participants