Conversation
Member
|
+1! |
Member
Author
|
@esteele any objections to me merging this one? |
Member
|
Any implications for existing installations? |
Member
Author
|
@esteele I can't see any. |
Member
|
👍 would be great to have this fix! |
jone
added a commit
to 4teamwork/ftw-buildouts
that referenced
this pull request
Mar 26, 2014
The buildout:zcml-additional-fragments variable helps wrapping the instanceX:zcml-additional option with a root configuration node, which allows to append to the buildout:zcml-additional-fragments any ZCML which will then properly set up. For more information regarding the source of the problem take a look at: plone/plone.recipe.zope2instance#13
lukasgraf
added a commit
to 4teamwork/ftw-buildouts
that referenced
this pull request
Mar 27, 2014
The buildout:zcml-additional-fragments variable helps wrapping the instanceX:zcml-additional option with a root configuration node, which allows to append to the buildout:zcml-additional-fragments any ZCML which will then properly set up. For more information regarding the source of the problem take a look at: plone/plone.recipe.zope2instance#13
Member
|
I just set up Travis CI for this package. Please update your branch to include .travis.yml so we can make sure the tests still pass. |
This makes it possible to use += assignments with zcml-additional.
Member
Author
|
@davisagli great, thanks! Rebased my branch onto master. |
davisagli
added a commit
that referenced
this pull request
Apr 9, 2014
…figure Always wrap contents of zcml-additional with a <configure /> node.
lukasgraf
added a commit
to 4teamwork/kgs
that referenced
this pull request
Apr 10, 2015
makes sure we're using a version of the recipe that supports using "zcml-additional += ..." assignments (see plone/plone.recipe.zope2instance#13)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This makes it possible to use
+=assignments withzcml-additional.Currently, the contents of
zcml-additionalare dumped as-is in999-additional-overrides.zcml. This means that you can't usezcml-additional +=assignments to add to an instance's additional ZCML from multiple places, because you will end up with a999-additional-overrides.zcmlthat contains multiple top level nodes (which isn't valid XML).In this PR I wrap the contents of
zcml-additionalin<configure />node (including the Zope XMLNS) before writing them to the file.This is done unconditionally, so even if
zcml-additionalonly contains one element, it will be wrapped. However, because<configure />directives can be nested to arbitrary depths (seezope.configuration.zopeconfigure, this should not be a problem, and the simplicity of the change outweighs the possible redundancy in my opinion.