Closed cspeekenbrink closed 1 year ago
Thank you for reporting this bug.
First of all, I do find it a bit odd that the auto uninstaller didn't detect the installation, which it usually does if the software has been installed through Chocolatey CLI (at least for this package).
The reason seems to be that it checks if Filezilla is installed by looking for this reg key:
Not necessarily, it isn't the name of the key itself that it checks, but rather it is the name that is displayed when you uninstall the application manually through Programs and Features
.
I do see that name has changed as well though
First of all, I do find it a bit odd that the auto uninstaller didn't detect the installation, which it usually does if the software has been installed through Chocolatey CLI (at least for this package).
Well, Chocolatey found the installation and reports back the version number too, but somehow doesn't detect the installation from the steps in the uninstallation script.
Not necessarily, it isn't the name of the key itself that it checks, but rather it is the name that is displayed when you uninstall the application manually through
Programs and Features
.
Ah, that makes sense. So the value I changed in the script is not the registry key name, but the name of the app in 'Programs and features'. Thanks!
Well, Chocolatey found the installation and reports back the version number too, but somehow doesn't detect the installation from the steps in the uninstallation script.
Chocolatey CLI itself doesn't detect it based on the uninstallation script, it has its own auto uninstaller that doesn't rely on it at all. But that is a different story. Since we have an uninstall script it should be fixed in the script itself first.
Would you be willing to submit a PR to fix this issue and correct the software name in both the chocolateyinstall.ps1
and chocolateyuninstall.ps1
scripts?
These should probably be replaceable values that get updated through the update.ps1
script since it uses the major version of the application (which it must do to prevent Filezilla Server to be picked up).
Sure would. It would be my first though, so I'll have to get acqainted with it. Getting right to it.
Chocolatey Version
1.1.0
Chocolatey License
No response
Package Version
3.60.2 (affects probably all 3.x versions)
Current Behaviour
Uninstallation doesn't see Filezilla as installed and doesn't actually uninstall it if it is.
Expected Behaviour
Filezilla should be uninstalled, but remains. Chocolatey flags it as being uninstalled.
Steps To Reproduce
Environment
Chocolatey Log
Anything else?
The reason seems to be that it checks if Filezilla is installed by looking for this reg key: HKLM\Software\Filezilla Client But (probably since v3.x) this key is called: HKLM\Software\FileZilla 3
So changing this line in the uninstallscript: $softwareNamePattern = 'FileZilla Client' to: $softwareNamePattern = 'FileZilla 3' Fixes it.