This release allows you to correctly detect the size of packets sent and received and addresses issue 74.
Backward Compatibility Mode
For backward compatibility, we continue to output in the same format, but now with correct packet size referring to the ICMP reply. Consider the following code snippet:
py
from pythonping import ping
ping('8.8.8.8', count=1, verbose=True)
This piece of code will continue to generate the following output, now with the packet size which correspond to the IP packet total length of the *ICMP reply*.
Reply from 8.8.8.8, 29 bytes in 5.28ms
New Implementation
The output format defaults to `legacy` and this will change in subsequent releases. You can change it right now be forcing it to `None` as follows:
py
from pythonping import ping
ping('8.8.8.8', count=1, verbose=True, out_format=None)
This will yield the results in the new output format, showing size of both request and response:
status=OK from=8.8.8.8 ms=5.14 bytes snt=29 rcv=29
A special thanks to s1198576 for having spotted the issue and doing some analysis with WireShark!