From 09715a9389960d42bf3d863f4b3e92630f7f653c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9mie?= Date: Thu, 28 Sep 2023 12:02:53 +0800 Subject: [PATCH 1/2] Fix parse_xml type for tmpl --- plugins/filter/parse_cli.py | 2 +- plugins/filter/parse_xml.py | 2 +- plugins/filter/vlan_expander.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/filter/parse_cli.py b/plugins/filter/parse_cli.py index c334a8d40..d9a3bb675 100644 --- a/plugins/filter/parse_cli.py +++ b/plugins/filter/parse_cli.py @@ -37,7 +37,7 @@ It defines how to parse the CLI output and return JSON data. - For example C(cli_data | ansible.netcommon.parse_cli(template.yml)), in this case C(cli_data) represents cli output. - type: string + type: str """ EXAMPLES = r""" diff --git a/plugins/filter/parse_xml.py b/plugins/filter/parse_xml.py index 78e45cfe8..0932971c7 100644 --- a/plugins/filter/parse_xml.py +++ b/plugins/filter/parse_xml.py @@ -36,7 +36,7 @@ It defines how to parse the XML output and return JSON data. - For example C(xml_data | ansible.netcommon.parse_xml(template.yml)), in this case C(xml_data) represents xml data option. - type: string + type: str """ EXAMPLES = r""" diff --git a/plugins/filter/vlan_expander.py b/plugins/filter/vlan_expander.py index b279564eb..359779916 100644 --- a/plugins/filter/vlan_expander.py +++ b/plugins/filter/vlan_expander.py @@ -27,7 +27,7 @@ data: description: - This option represents a string containing the range of vlans. - type: string + type: str required: True """ From 8e8aab12943fedc8d8cf0273fbc8df3052ee3601 Mon Sep 17 00:00:00 2001 From: KB-perByte Date: Tue, 17 Oct 2023 18:00:25 +0530 Subject: [PATCH 2/2] add changelog --- changelogs/fragments/fix_attribute_type.yaml | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 changelogs/fragments/fix_attribute_type.yaml diff --git a/changelogs/fragments/fix_attribute_type.yaml b/changelogs/fragments/fix_attribute_type.yaml new file mode 100644 index 000000000..92fc370dd --- /dev/null +++ b/changelogs/fragments/fix_attribute_type.yaml @@ -0,0 +1,3 @@ +--- +bugfixes: + - Fix attribute types from string to str in filter plugins.