Resource module cisco.iosxr.iosxr_interfaces is not returning facts for with new collection version 5.0.3.
Tested on Ansible 2.13. Gather facts errors out with below error message:
TASK [yeti.netcommon.collect_facts : Gather Cisco Network Facts] ****
task path: /home//.ansible/collections/ansible_collections/yeti/netcommon/roles/collect_facts/tasks/cisco.iosxr.iosxr/network_facts.yml:2
The full traceback is:
File "/home//.ansible/collections/ansible_collections/ansible/netcommon/plugins/module_utils/network/common/facts/facts.py", line 135, in get_network_resources_facts
inst.populate_facts(
File "/home//.ansible/collections/ansible_collections/cisco/iosxr/plugins/module_utils/network/iosxr/facts/l2_interfaces/l2_interfaces.py", line 70, in populate_facts
obj = self.render_config(self.generated_spec, conf)
File "/home//.ansible/collections/ansible_collections/cisco/iosxr/plugins/module_utils/network/iosxr/facts/l2_interfaces/l2_interfaces.py", line 132, in render_config
config["q_vlan"].append(int(dot1q.split(" ")[0]))
fatal: [ASR9K-01]: FAILED! => {
"changed": false,
"invocation": {
"module_args": {
"available_network_resources": false,
"gather_network_resources": [
"l3_interfaces",
"l2_interfaces",
"lldp_interfaces",
"interfaces",
"acl_interfaces",
"lag_interfaces"
],
"gather_subset": [
"interfaces"
]
}
},
"msg": "invalid literal for int() with base 10: '2900-2902'"
}
SUMMARY
Resource module cisco.iosxr.iosxr_interfaces is not returning facts for with new collection version 5.0.3. Tested on Ansible 2.13. Gather facts errors out with below error message: TASK [yeti.netcommon.collect_facts : Gather Cisco Network Facts] **** task path: /home//.ansible/collections/ansible_collections/yeti/netcommon/roles/collect_facts/tasks/cisco.iosxr.iosxr/network_facts.yml:2
The full traceback is:
File "/home//.ansible/collections/ansible_collections/ansible/netcommon/plugins/module_utils/network/common/facts/facts.py", line 135, in get_network_resources_facts
inst.populate_facts(
File "/home//.ansible/collections/ansible_collections/cisco/iosxr/plugins/module_utils/network/iosxr/facts/l2_interfaces/l2_interfaces.py", line 70, in populate_facts
obj = self.render_config(self.generated_spec, conf)
File "/home//.ansible/collections/ansible_collections/cisco/iosxr/plugins/module_utils/network/iosxr/facts/l2_interfaces/l2_interfaces.py", line 132, in render_config
config["q_vlan"].append(int(dot1q.split(" ")[0]))
fatal: [ASR9K-01]: FAILED! => {
"changed": false,
"invocation": {
"module_args": {
"available_network_resources": false,
"gather_network_resources": [
"l3_interfaces",
"l2_interfaces",
"lldp_interfaces",
"interfaces",
"acl_interfaces",
"lag_interfaces"
],
"gather_subset": [
"interfaces"
]
}
},
"msg": "invalid literal for int() with base 10: '2900-2902'"
}
ISSUE TYPE
COMPONENT NAME
cisco.iosxr.iosxr_interfaces
ANSIBLE VERSION
COLLECTION VERSION
CONFIGURATION
OS / ENVIRONMENT
Cisco IOS XR Software, Version 6.5.3
yeti_network_services: - configs: # l3 loopback config block - interfaces: # interfaces module - name: loopback64 description: TEST LOOPBACK DESCRIPTION state: merged - l3_interfaces: # l3_interfaces module - name: loopback64 ipv4: - address: 192.168.1.3/31 state: merged