I'm new to Python and used ChatGPT to generate a script that automatically creates a visual diagram after running terraform apply. The script (in diagramOriginal.py) aims to read the Terraform state file (tfstate) stored in S3+DynamoDB and use the Diagrams library to generate the diagram. However, I'm encountering an error, as below.
I'd appreciate any help with debugging the error or if anyone has existing scripts for automatic cloud resource diagram generation. Ideally, I'd like to integrate this functionality into Azure Pipelines.
Error: Traceback (most recent call last):
│ File "C:\diagramOriginal.py", line 41, in <module>
│ create_diagram_from_applied_state()
│ File "C:\diagramOriginal.py", line 28, in create_diagram_from_applied_state
│ diagram.render("arch1.png")
│ TypeError: Diagram.render() takes 1 positional argument but 2 were given
I'm testing this locally on Windows 11. I'd appreciate any help with debugging the error or if anyone has existing scripts for automatic cloud resource diagram generation. Ideally, I'd like to integrate this functionality into Azure Pipelines.
buran write Apr-30-2024, 07:19 AM:
Please, use proper tags when post code, traceback, output, etc. This time I have added tags for you.
See BBcode help for more info.
Please, use proper tags when post code, traceback, output, etc. This time I have added tags for you.
See BBcode help for more info.