is there a way to do a 'pre-handler' with generic setups, similar to
post_handler=".setuphandlers.post_install"
But before ?
(or is the only option to make more profile(s) and a dependency metadata.xml ?)
is there a way to do a 'pre-handler' with generic setups, similar to
post_handler=".setuphandlers.post_install"
But before ?
(or is the only option to make more profile(s) and a dependency metadata.xml ?)
What is your use case?
The folders / content is made (with plone.api) in a setuphandler, so I need at least to "run" 'portlets.xml' after that.
..and all of this can only be done properly after your site up with all dependencies and all configurations have been installed properly. There is no valid use case for such a thing as a pre-handler.
How?
If portlets for content items are installed with portlets.xml and content is added in setuphandler script, the profile with portlets.xml needs to run 'last' to be assigned to '/some_folder/something (?)
The only approach I can think of is:
Or am I missing something here ?
You can also create content - if needed - using GenericSetup.
I am the one who added post_handler
to GenericSetup in 2016, see this PR. And this same PR introduces pre_handler
, which works exactly the same as post_handler
. The order is:
pre_handler
, if available.post_handler
, if available.Thanks a lot