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

[bug] "Unable to load Chocolatey GUI assembly" after installing Chocolatey GUI. #83389

Closed
hwhsu1231 opened this issue Oct 12, 2022 · 11 comments
Closed
Labels
Area-External Issue-Bug It either shouldn't be doing this or needs an investigation.
Milestone

Comments

@hwhsu1231
Copy link

Brief description of your issue

After installing Chocolatey GUI and then launching it, an error message showed up:

Unable to load Chocolatey GUI assembly.
'ChocolateyGui.Common.Windows.Bootstrapper' 的初始設定式發生例外狀況。

image

Steps to reproduce

  1. Install Chocolatey GUI by typeing winget command:

    winget install Chocolatey.ChocolateyGUI
  2. Click the icon to launch it.

Expected behavior

Open the window of Chocolatey.

Actual behavior

Show the error message.

Environment

Windows 封裝管理員 v1.3.2691
Copyright (c) Microsoft Corporation. 著作權所有,並保留一切權利。

Windows: Windows.Desktop v10.0.22621.521
系統架構: X64
套件: Microsoft.DesktopAppInstaller v1.18.2691.0

記錄檔: %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir

連結
------------------------------------------------------------------------
隱私權聲明       https://aka.ms/winget-privacy
授權合約         https://aka.ms/winget-license
第三方聲明       https://aka.ms/winget-3rdPartyNotice
首頁             https://aka.ms/winget
Windows 市集條款 https://www.microsoft.com/en-us/storedocs/terms-of-sale
@ghost ghost added the Needs-Triage This work item needs to be triaged by a member of the core team. label Oct 12, 2022
@Trenly
Copy link
Contributor

Trenly commented Oct 12, 2022

Here's the English localized error message -
image

Seems to me like it's an issue with the application itself and not with WinGet, especially since the issue occurs when downloading and running the installer directly from the GitHub

Edit: Found the issue - it requires Chocolatey CLI in order to run chocolatey/ChocolateyGUI#943 (comment)

For example, Chocolatey GUI isn't a standalone application. It requires Chocolatey CLI to be installed in order for it to operate. Chocolatey GUI doesn't automatically install Chocolatey CLI.

@hwhsu1231
Copy link
Author

Then, can WinGet support installing Chocolatey CLI?

@SpecterShell
Copy link
Contributor

#21877

@denelon denelon transferred this issue from microsoft/winget-cli Oct 13, 2022
@denelon denelon added Issue-Bug It either shouldn't be doing this or needs an investigation. Area-External and removed Needs-Triage This work item needs to be triaged by a member of the core team. labels Oct 13, 2022
@Wrdle
Copy link

Wrdle commented Oct 16, 2022

I actually still have this error at the moment with chocolatey CLI installed

image

@KattPhloxworthy
Copy link

KattPhloxworthy commented Jun 11, 2023

I found that if the new version of Chocolatey GUI (2.0.0) doesn't find the version of Chocolatey wants to run with, even if choco.exe is actually present, it will throw this exception. On one machine, I had attempted (operative word here) to upgrade Chocolatey from 1.3.1 to 2.0.0, but it apparently didn't work, so when I tried to run the latest Chocolatey GUI, I would get this error. Chocolatey ended up still being at 1.3.1. Then, I found this page. I tried the choco upgrade chocolatey -y at a command prompt, and it insisted I had already upgraded it. I tried doing an uninstall, but I couldn't reinstall because the command was still present on my system. I ended up forcing the upgrade, adding -f. THEN the new Chocolatey GUI started working.

Basically, make sure that Chocolatey itself actually upgraded. If not, forcibly upgrade it at an administrator prompt.

I hope this helps those who are having problems after an upgrade of both Chocolatey and Chocolatey GUI.

--Katt. =^.^=

@ruben-grossmann
Copy link

I found that if the new version of Chocolatey GUI (2.0.0) doesn't find the version of Chocolatey wants to run with, even if choco.exe is actually present, it will throw this exception. On one machine, I had attempted (operative word here) to upgrade Chocolatey from 1.3.1 to 2.0.0, but it apparently didn't work, so when I tried to run the latest Chocolatey GUI, I would get this error. Chocolatey ended up still being at 1.3.1. Then, I found this page. I tried the choco upgrade chocolatey -y at a command prompt, and it insisted I had already upgraded it. I tried doing an uninstall, but I couldn't reinstall because the command was still present on my system. I ended up forcing the upgrade, adding -f. THEN the new Chocolatey GUI started working.

Basically, make sure that Chocolatey itself actually upgraded. If not, forcibly upgrade it at an administrator prompt.

I hope this helps those who are having problems after an upgrade of both Chocolatey and Chocolatey GUI.

--Katt. =^.^=

Thanks. Had the same problem. choco upgrade chocolatey -f fixed the problem for me.

@geomorillo
Copy link

I found that if the new version of Chocolatey GUI (2.0.0) doesn't find the version of Chocolatey wants to run with, even if choco.exe is actually present, it will throw this exception. On one machine, I had attempted (operative word here) to upgrade Chocolatey from 1.3.1 to 2.0.0, but it apparently didn't work, so when I tried to run the latest Chocolatey GUI, I would get this error. Chocolatey ended up still being at 1.3.1. Then, I found this page. I tried the choco upgrade chocolatey -y at a command prompt, and it insisted I had already upgraded it. I tried doing an uninstall, but I couldn't reinstall because the command was still present on my system. I ended up forcing the upgrade, adding -f. THEN the new Chocolatey GUI started working.

Basically, make sure that Chocolatey itself actually upgraded. If not, forcibly upgrade it at an administrator prompt.

I hope this helps those who are having problems after an upgrade of both Chocolatey and Chocolatey GUI.

--Katt. =^.^=

choco upgrade chocolatey -f this fixed it

@alexricher
Copy link

Ditto! 👍 I had this popup upon launching a Chocolatey GUI instance.

---------------------------

---------------------------
Unable to load Chocolatey GUI assembly. The type initializer for 'ChocolateyGui.Common.Windows.Bootstrapper' threw an exception.
---------------------------
OK   
---------------------------

I ended up doing choco upgrade chocolatey -f to force upgrade it, and it works as before now. Thanks!

@JulyIghor
Copy link

This issue occurs every time Windows restarts with ChocolateyGui open and installing updates.

@rodrigue1507
Copy link

thanks KattPhloxworthy

I found that if the new version of Chocolatey GUI (2.0.0) doesn't find the version of Chocolatey wants to run with, even if choco.exe is actually present, it will throw this exception. On one machine, I had attempted (operative word here) to upgrade Chocolatey from 1.3.1 to 2.0.0, but it apparently didn't work, so when I tried to run the latest Chocolatey GUI, I would get this error. Chocolatey ended up still being at 1.3.1. Then, I found this page. I tried the choco upgrade chocolatey -y at a command prompt, and it insisted I had already upgraded it. I tried doing an uninstall, but I couldn't reinstall because the command was still present on my system. I ended up forcing the upgrade, adding -f. THEN the new Chocolatey GUI started working.

Basically, make sure that Chocolatey itself actually upgraded. If not, forcibly upgrade it at an administrator prompt.

I hope this helps those who are having problems after an upgrade of both Chocolatey and Chocolatey GUI.

--Katt. =^.^=

thanks "choco upgrade chocolatey -f" works for me !!

Copy link
Contributor

Hello @hwhsu1231,

This issue has been identified as requiring a fix from a third party or external repository. Since there has been no recent activity on this issue, it will be automatically closed.

Template: msftbot/noRecentActivity/areaExternal

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-External Issue-Bug It either shouldn't be doing this or needs an investigation.
Projects
None yet
Development

No branches or pull requests