Closed philippemerle closed 3 years ago
What you are experiencing here is exactly the same that happens with SOL001 (maybe you are playing with them).
I already discussed this with TAL and we are about to merge my changes (see PR#72) that provide a new quirk imports.ignore.topology_template.
If you are in a hurry and want to test, you may play with my fork at jpc4242/puccini (but my fork is intended to just prepare pull requests for Tal's main project; I encourage you to stay here) UPDATE: Tal already merged the PR, so the new quirks are available.
I forgot to mention the original issue in case you want to look at it: it was #51
What you are experiencing here is exactly the same that happens with SOL001 (maybe you are playing with them).
Yes I am playing with them.
Then you will find useful the other quirk added in the same pull request
This behavior is now supported via --quirk imports.topology_template.ignore
.
Thank you Tal.
Why is it resolved as a quirk? I see nowhere in TOSCA spec that an imported file can not declare a topology template. So the default behaviour should be to not produce a problem when an imported file declares a topology template. Anyway.
Because this seems wrong to me -- there can be only one topology template. There is nothing in the grammar that could explain how two topology templates would be merged together. The spec simply doesn't specify what would happen in this case and in my interpretation, which always errs on the side of being strict, silently ignoring errors is not a good idea by default.
There seems to be agreement to make this interpretation explicit in TOSCA 2.0, where we are focusing much more on building profiles and generally defining how "import" works more clearly and strictly.
Importing a file containing a topology template seems to be unsupported by Puccini 0.18.0.
Following is the importing template:
Following is the imported template:
A problem is signaled when compiling the importing template: