chocolatey / ChocolateyGUI

A delicious GUI for Chocolatey
https://docs.chocolatey.org/en-us/chocolatey-gui/
Apache License 2.0
1.61k stars 249 forks source link

Unhandled Exception When Non-Standard Config Input #972

Open ryanrichter94 opened 1 year ago

ryanrichter94 commented 1 year ago

Checklist

What You Are Seeing?

Chocolatey GUI crashes with an Unhandled Exception when navigating to the settings window of the GUI interface. It does this when a non-standard config entry is within the chocolatey.config file. For instance if someone mis types a config set creating a new line in the config file.

What is Expected?

Chocolatey GUI should account for this scenario and give a better warning than unhandled exception. Such as unable to read chocolatey config.

How Did You Get This To Happen?

  1. Run the following config command as if you mistyped it. Accidentally adding a new line and not editing the existing value. choco config set -name=intuneTenantGUID --value=14d937f1-3ed9-4448-bac6-567ec572acb4
  2. Open Chocolatey GUI.
  3. Attempt to open the settings menu.

image

System Details

Installed Packages

7zip 22.1
7zip.install 22.1
chocolatey 1.2.1
chocolatey-agent 1.1.1
chocolatey-compatibility.extension 1.0.0
chocolatey-core.extension 1.4.0
chocolatey-dotnetfx.extension 1.0.1
chocolatey.extension 5.0.1
chocolateygui 1.1.0
DotNet4.5.2 4.5.2.20140902
dotnetfx 4.8.0.20220524
GoogleChrome 108.0.5359.95
KB2919355 1.0.20160915
KB2919442 1.0.20160915
microsoft-edge 108.0.1462.42
notepadplusplus 8.4.7
notepadplusplus.install 8.4.7
vscode 1.73.1
vscode.install 1.73.1

Output Log

2022-12-20 08:06:24.122 -05:00 [Fatal] Unhandled Exception

Additional Context