unfurl
unfurl copied to clipboard
unfurl export "concise" mode adds extra parenthesis causing syntax errors in Python file generated from TOSCA YAML file
example with snippet from https://docs.unfurl.run/configurators.html :
apiVersion: unfurl/v1alpha1
kind: Ensemble
spec:
service_template:
imports:
- repository: unfurl
file: tosca_plugins/artifacts.yaml
topology_template:
node_templates:
terraform-example:
type: tosca:Root
artifacts:
ripgrep:
type: artifact.AsdfTool
file: ripgrep
properties:
version: 13.0.0
interfaces:
Standard:
configure:
implementation: ripgrep
inputs:
cmd: rg search
using the command:
UNFURL_EXPORT_PYTHON_STYLE=concise unfurl -vv export --format python ex1.yaml
generates the error:
TOSCA failed to format /Users/julienhoward/unfurl/docs/ex1.py: Cannot parse: 18:17: file='ripgrep', ))
the full line in ex1.py being
terraform_example.ripgrep = artifact_AsdfTool("ripgrep", version='13.0.0',
file='ripgrep', ))