chocolatey-packages icon indicating copy to clipboard operation
chocolatey-packages copied to clipboard

qtcreator does not uninstall/update properly

Open michaelweghorn opened this issue 2 years ago • 0 comments

Describe the bug The qtcreator package does not uninstall or update properly. When uninstalling, files belonging to the package remain in C:\tools\qtcreator, and files from an old version can cause problems after a package upgrade.

To Reproduce Steps to reproduce the behavior:

  1. Install previous version of the qtcreator package: choco install -y --version=7.0.2 qtcreator
  2. start Qt Creator, e.g. from the start menu -> all OK
  3. close Qt Creator again
  4. upgrade to the current package version (currently 8.0.0): choco upgrade -y qtcreator
  5. start Qt Creator again

Result: A dialog shows up, saying that a plugin failed to load, and the details section lists plugins that have the version number of the previously installed Qt Creator version as dependencies that failed to load:

screenshot_qtcreator_plugin_errors_after_upgrade

Expected behavior Qt Creator should start without showing any error message.

Desktop (please complete the following information):

  • OS: Windows 10 21H2
  • Chocolatey version: 1.1.0
  • Chocolatey package: qtcreator
  • Package version: 8.0.0

Chocolatey Install/Uninstall log https://gist.github.com/michaelweghorn/3cb4f561054f0f2c3a9ddb03bfffe05a

Additional context

The problem does not appear when uninstalling qtcreator, manually deleting C:\tools\qtcreator and installing the new qtcreator version after that instead of doing a package upgrade. However, the uninstallation script should probably not remove the complete directory, since it also contains files of the qtcreator-cdbext package, which would otherwise get removed on upgrade of just the qtcreator package as well.

michaelweghorn avatar Jul 22 '22 08:07 michaelweghorn