Y
Y
yahabrovec2018-09-18 23:45:43
Python
yahabrovec, 2018-09-18 23:45:43

how to check internet connection speed in python

Hello everyone
There was a problem to find out the speed of the Internet connection straight from the python code. Of course, you could download some file, then divide it by the download time and then bam and like the rules. But I need to recognize it directly in the code, as in any downloaders like youtube-dl or wget. There, next to the file size, there is a download speed. I need the same.
Tell me what to do or where to dig

Answer the question

In order to leave comments, you need to log in

4 answer(s)
V
VoidVolker, 2018-09-18
@VoidVolker

Download speed = amount downloaded / download time. So, in order to find out the speed, in any case, you need to download something for a certain period of time. Nothing else. Any loaders in the same way and consider the speed.

A
Alex F, 2018-09-19
@delvin-fil

A very detailed answer .

Z
zlo1, 2018-09-19
@zlo1

Python utility
https://github.com/sivel/speedtest-cli

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question