Maurits van Rees wrote:
> Someone has a site with profile hoopyfrood up to date. He has no idea
> what this does, it was just applied as a dependency of another add-on.
> He adds an addon with profile towel to the buildout config. This
> requires a new version of the package that has profile hoopyfrood. Fine,
> he updates the version pins, runs buildout and restarts the site.
> He installs the towel add-on.
I didn't think this would be the normal procedure: Upgrading packages
just because a new add-on depends on new version of these packages. But
maybe I'm just not using as many add-ons as other people do.
> Old answer: no matter what the state of the hoopyfrood profile, we apply
> it. This may be mostly harmless (I swear I did not plan this culture
> reference), but it does more than necessary and may be harmful in some
> My answer: apply the upgrade step of hoopyfrood. Everybody happy.
> Your answer: give an error, pointing to the Upgrades tab, telling him to
> run the upgrades of hoopyfrood first? Then nothing happens.
> Your answer may be fine when applying a profile in the ZMI, but then
> again, I have updated the pull request to give the user more options in
> the ZMI so that may be fine already. So maybe you are happy with that
Your mail with the screen shot was delayed, so I didn't see it before I
wrote my reply.
X-Mailman-Approved-At: Fri, 11 Sep 2015 15:20:01 +0200
Did someone have to approve that manually?
Anyway: Looks like a tab that tries to make everybody happy. It's too
complex, but that's not your fault.
> From the point of view of existing code in add-ons that call
> runAllImportStepsFromProfile and expect it to maybe do too much but at
> least work, your answer would be a regression: either nothing is done or
> you get an exception.
I see: The old implementation of runAllImportStepsFromProfile wasn't
written with upgrades in mind, but obviously it did that job good enough
that people started to use it for that purpose. And it did that job bad
enough that you started to improve the implementation.
> BTW, the add-ons control panel in Plone 5 lists the available upgrades
> first, and then the installable new add-ons. We could improve the ZMI
> similarly, like:
> - add a warning at the top of the Imports tab if there are upgrades
> - Show on the Upgrades tab which profiles actually have upgrades that
> need to be applied. Now I sometimes click through the entire list to
> check this.
> Maybe something for another pull request.
> But, for me, this is not about how it works in the ZMI. I am sure with
> some back and forth like this we can work something out. It is mostly
> about: what happens when in code you do runAllImportStepsFromProfile
> with the default settings.
> BTW 2, Plone 5 is still also using CMFQuickInstaller, but that is going
> the way of the dodo. Slowly.
I didn't have a look at the Plone 5 control panel, but as you describe
it, something similar would be quite useful in the portal_setup UI. But
the Import tab has already too many options for rare use cases. It might
be better to add a new tab for importing add-ons.
Zope-CMF maillist - Zope-CMF@zope.org
See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests