Closed chidanandpujar closed 1 month ago
juniper.device.ping
JUNOS Evolved
juniper.device.ping does not handle when packet loss has float values .
msg: 'Packet loss 33.3333 not an integer. Response: b''\n x.x.x.x\n x.x.x.x\n 64\n \n 3\n 2\n 33.3333\n 33\n 146\n 89\n 56\n \n \n\n'''
- name: Test reachability to device using do-not-fragment and rapid juniper.device.ping: dest: x.x.x.x do_not_fragment: false rapid: true size: 64 count: 3 acceptable_percent_loss: 30 ignore_errors: true register: test_ping TASK [Test reachability to device using do-not-fragment and rapid] ******************************************************************************************************** fatal: [10.220.24.28]: FAILED! => changed=false acceptable_percent_loss: '30' count: '3' dest: x.x.x.x dest_ip: x.x.x.x do_not_fragment: false host: x.x.x.x interface: null msg: 'Packet loss 33.3333 not an integer. Response: b''<ping-results>\n <target-host>x.x.x.x</target-host>\n <target-ip>x.x.x.x</target-ip>\n <packet-size>64</packet-size>\n <probe-results-summary>\n <probes-sent>3</probes-sent>\n <responses-received>2</responses-received>\n <packet-loss>33.3333</packet-loss>\n <rtt-minimum>33</rtt-minimum>\n <rtt-maximum>146</rtt-maximum>\n <rtt-average>89</rtt-average>\n <rtt-stddev>56</rtt-stddev>\n </probe-results-summary>\n <ping-success/>\n</ping-results>\n''' packet_loss: '33.3333' packets_received: '2' packets_sent: '3' rapid: true routing_instance: null size: '64' source: null source_ip: null timeout: '120' ttl: null ...ignoring
Fixed via https://github.com/Juniper/ansible-junos-stdlib/pull/673
Issue Type
Module Name
juniper.device.ping
OS / Environment
JUNOS Evolved
Summary
juniper.device.ping does not handle when packet loss has float values .
msg: 'Packet loss 33.3333 not an integer. Response: b''\n x.x.x.x \n x.x.x.x \n 64 \n \n 3 \n 2 \n 33.3333 \n 33 \n 146 \n 89 \n 56 \n \n \n \n'''
Steps to reproduce
Actual results