southbridgeio / zabbix-review-export-import

Clone of zabbix-review-export with added import object(s) feature
https://gitlab.com/devopshq/zabbix-review-export
50 stars 30 forks source link

Error when trying to import a yaml template file to zabbix #15

Closed ZouhairCharef closed 1 year ago

ZouhairCharef commented 1 year ago

Dears, I try to import this yaml template file using the import script, but I face this error:

File "/path-to-the-script/zabbix-import.py", line xxx, in import_template
new_template = yml["templates"]["template"]
TypeError: list indices must be integers or slices, not str

and this this the part of code: https://github.com/southbridgeio/zabbix-review-export-import/blob/master/zabbix-import.py#L868

Can someone please help me on that? And thanks in advance.