Skip to content

Chocolatey GUI - Unable to locate config file #1086

@gep13

Description

@gep13

When starting Chocolatey GUI, it is possible to be met with the following error message:

image

Failed to start application.
Could not find a part of the path 'C:\Program Files (x86)\Chocolatey GUI\config\chocolatey.config'
More details available in application logs.

This problem is reproducible on any machine by:

  • Closing Chocolatey GUI
  • Open the settings page for System Environment Variables
  • Deleting the ChocolateyInstall environment variable
  • Starting Chocolatey GUI

The issue here is that Chocolatey GUI is requesting the installation location for Chocolatey via Chocolatey.Lib, and this is determined based on the presence of the ChocolateyInstall environment variable. When this doesn't exist, or contains nothing, the directory for the currently executing assembly is returned. When running Chocolatey GUI, this location is C:\Program Files (x86)\Chocolatey GUI as per the error message above.

When we have seen this happen, Chocolatey and Chocolatey GUI have been provisioned via Intune, and over an RDP connection. The suspicion is that the environment variables that Chocolatey creates as part of its installation process aren't being persisted onto the machine correctly.

As a result, the workaround is to first reboot the machine, and then Chocolatey GUI will work as expected.

Metadata

Metadata

Assignees

No one assigned

    Labels

    0 - TriagingIssue is accepted, but a milestone has yet to be added for the issue.BugIssues where something has happened which was not expected or intended.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions