chocolatey log: chocolatey.log.txt
That's interesting and definitely not desired. I find it odd that it doesn't handle that situation accurately.
As the issue template requested, can you provide a gist of the debug / verbose output? You should have this from what you ran already. It will be in C:\ProgramData\chocolatey\logs\chocolatey.log.
Once we have that, it will provide some better terms for evaluation.
Ok, i'll post it on monday.
Thanks for Your efforts!
Thank you. 馃憤
I've attached chocolatey.log file: https://github.com/chocolatey/choco/files/660065/chocolatey.log.txt
Command issued in console was: choco upgrade itsk.af.local -y
Package dependency tree looks like this:
itsk.af.local
-> itsk.af.db.local
-> itsk.af.dispatcher.local
-> itsk.af.integration.local
-> itsk.af.scheduler.local
-> itsk.af.api.local
-> itsk.af.client.local
-> itsk.af.frontend.local
Each package has tools\chocolateyBeforeModify.ps1 with the same content:
Write-Host $MyInvocation.MyCommand.Definition
But tools\chocolateyBeforeModify.ps1 gets called only for itsk.af.local
This still appears to be a broken, please fix.
I think we know why this is occurring - we'll prolly need to do some additional checks closer to when those dependent packages are discovered for upgrade.
We have the same problem as well. We're using a meta-package which depends on multiple packages.
Dependencies for example:
meta-package
-> install-pkg-a
-> install-pkg-b
However, one of the parent packages install-pkg-a needs to uninstall the installed msi first before re-installing. We use the chocolateyBeforeModify.ps1 to uninstall the previous version before upgrading. This is working well when doing choco upgrade install-pkg-a, it managed to uninstall the previous version. But when doing choco upgrade meta-package, the new version of install-pkg-a does not run chocolateyBeforeModify.ps1. My next attempt on this issue is to put uninstall steps from chocolateyBeforeModify.ps1 into chocolateyinstall.ps1.
Users of keepass package (including me) are repeatedly facing this issue (just see the comments). Would it be possible to fix this, please?
Most helpful comment
We have the same problem as well. We're using a meta-package which depends on multiple packages.
Dependencies for example:
meta-package
-> install-pkg-a
-> install-pkg-b
However, one of the parent packages install-pkg-a needs to uninstall the installed msi first before re-installing. We use the
chocolateyBeforeModify.ps1to uninstall the previous version before upgrading. This is working well when doingchoco upgrade install-pkg-a, it managed to uninstall the previous version. But when doingchoco upgrade meta-package, the new version of install-pkg-a does not runchocolateyBeforeModify.ps1. My next attempt on this issue is to put uninstall steps fromchocolateyBeforeModify.ps1intochocolateyinstall.ps1.