ChocolateyGUI icon indicating copy to clipboard operation
ChocolateyGUI copied to clipboard

Unhandled Exception When Non-Standard Config Input

Open ryanrichter94 opened this issue 2 years ago • 0 comments

Checklist

  • [X] I have verified this is the correct repository for opening this issue.
  • [X] I have verified no other issues exist related to my problem.
  • [X] I have verified this is not an issue for a specific package.
  • [X] I have verified this issue is not security related.

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

  • Operating System: 10.0.19045.0
  • Windows PowerShell version: 5.1.19041.1682
  • Chocolatey CLI Version: 1.2.1
  • Chocolatey Licensed Extension version: 5.0.1
  • Chocolatey GUI version: 1.1.0
  • Chocolatey License type: Business
  • Terminal/Emulator: Windows Powershell

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

ryanrichter94 avatar Dec 20 '22 13:12 ryanrichter94