ChrisTitusTech / winutil

Chris Titus Tech's Windows Utility - Install Programs, Tweaks, Fixes, and Updates
MIT License
24.7k stars 1.5k forks source link

Install/Update fails if Discord is already installed and is selected #2964

Closed WrayOfSunshine closed 3 weeks ago

WrayOfSunshine commented 1 month ago

Describe the bug

If Discord is already installed (even if installed via WinUtil) and then is selected when choosing "Install/Upgrade Selected", the script does not fail over to the next install/upgrade when it should.

To Reproduce

Steps to reproduce the behavior:

  1. Click on Install tab.
  2. Select Discord
  3. Click on "Install/Upgrade Selected"
  4. After install, click on "Install/Upgrade Selected" again (replicates error generated if you use "Get Installed" and then do an Install/Upgrade).
  5. Script hangs at "Attempt installation of Discord.Discord with user scope"

Expected behavior

The script should get the error report from winget that it cannot upgrade this package and move on to the next package or finish, as appropriate. This happens with other packages.

Additional context

Notable - if I ctrl+c on the powershell window, I then get a popup asking for user credentials to be utilized to install Discord (this does not appear for me until I attempt to fail out of the install). Canceling that credential window gives an error about not being provided credentials, but still does not fail out of the install attempt sufficiently to allow working with the GUI.

WrayOfSunshine commented 1 month ago

I would personally prefer to see Discord installed on an all-users basis rather than per-user, in any case, but that's not relevant to this particular issue.

ChrisTitusTech commented 1 month ago

The Discord app auto updates. I'd recommend not having it checked when updating. I'll look into omiting if it detects it already installed.