Skip to content

[BUG] Using Chocolatey causes choco.exe process to hang on update check infinitely using CPU cycles. #3708

@DimkaTsv

Description

@DimkaTsv

Please confirm these before moving forward

  • I have searched for my issue and have not found a work-in-progress/duplicate/resolved issue.
  • I have tested that this issue has not been fixed in the latest (beta or stable) release.
  • I have checked the FAQ section for solutions.
  • This issue is about a bug (if it is not, please use the correct template).

UniGetUI Version

3.2.0

Windows version, edition, and architecture

Windows 11 Pro 23H2 22631.5413 // 1000.22700.1106.0 (x64)

Describe your issue

When using UniGetUI Chocolatey manager process, choco.exe can get stuck permanently trying to find updated packages.
Each attempt to find updates during UniGetUI launch spawns two stuck choco.exe threads [list and outdated commands], each using quite a chunk of CPU power. After launch each attempt spawns +1 process.

They won't terminate with time (despite 60 seconds timeout), neither they will terminate if UniGetUI becomes closed. They will unattach from process and continue hanging eating out CPU power.

Issue happens with both UniGetUI own, as well as system wide Chocolatey called via UniGetUI one.

Steps to reproduce the issue

  1. Launch UniGetUI
  2. Watch task manager (or other system/load monitoring tool)...

Well, that is pretty much all that's needed.
Sometimes it can take one or two tries to start happening for me, but after it starts, it will happen 100% of times.

UniGetUI Log

[01.06.2025 22:28:48] Manager Chocolatey failed to list installed packages with exception TimeoutException: Task _getInstalledPackages for manager Chocolatey did not finish after 60 seconds, aborting.  You may disable timeouts from UniGetUI Advanced Settings
[01.06.2025 22:28:48] Since this was the first attempt, Chocolatey.AttemptFastRepair() will be called and the procedure will be restarted
[01.06.2025 22:28:48] Manager Chocolatey failed to list available updates with exception TimeoutException: Task _getInstalledPackages for manager Chocolatey did not finish after 60 seconds, aborting.  You may disable timeouts from UniGetUI Advanced Settings
[01.06.2025 22:28:48] Since this was the first attempt, Chocolatey.AttemptFastRepair() will be called and the procedure will be restarted
[01.06.2025 22:29:48] Error finding updates on manager Chocolatey
[01.06.2025 22:29:48] Error finding installed packages on manager Chocolatey
[01.06.2025 22:29:48] System.TimeoutException: Task _getInstalledPackages for manager Chocolatey did not finish after 60 seconds, aborting.  You may disable timeouts from UniGetUI Advanced Settings
                         at UniGetUI.PackageEngine.ManagerClasses.Manager.PackageManager._getAvailableUpdates(Boolean SecondAttempt) in C:\SomePrograms\WingetUI-Store\src\UniGetUI.PackageEngine.PackageManagerClasses\Manager\PackageManager.cs:line 206
[01.06.2025 22:29:48] System.TimeoutException: Task _getInstalledPackages for manager Chocolatey did not finish after 60 seconds, aborting.  You may disable timeouts from UniGetUI Advanced Settings
                         at UniGetUI.PackageEngine.ManagerClasses.Manager.PackageManager._getInstalledPackages(Boolean SecondAttempt) in C:\SomePrograms\WingetUI-Store\src\UniGetUI.PackageEngine.PackageManagerClasses\Manager\PackageManager.cs:line 255

Package Managers Logs

Logged subprocess-based task on manager Chocolatey. Task type is ListUpdates
Subprocess executable: "C:\Users\DimkaTsv\AppData\Local\UniGetUI\Chocolatey\choco.exe"
Command-line arguments: " outdated "
Process start time: 01.06.2025 22:31:31
Process end time:   UNFINISHED

-- Process STDOUT
  Chocolatey v2.4.3
  Outdated Packages
   Output is package name | current version | available version | pinned?

Return code: Process has not finished yet

Relevant information

Perhaps issue roots in fact that i have 0 packages installed via Chocolatey. So it cannot find any to update and retries infinitely?
Disabling Chocolatey makes issue disappear (but that's quite obvious...)
Switching to diffetent Chocolatey mode makes issue disappear for one or two attempts, then it returns.

Screenshots and videos

UniGetUI Chocolatey:
Image

System-wide Chocolatey:
Image

Metadata

Metadata

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions