google-speedtest-chart icon indicating copy to clipboard operation
google-speedtest-chart copied to clipboard

Two suggestions for improvements

Open SecuritySimon opened this issue 5 years ago • 0 comments

I love this code, awesome. I have two suggestions.

  1. Please allow a way to pass in a server ID to pass to the speedtest-cli, or at least provide a conf file. I just hacked the following into your code. (Not great with git to be able to submit a pull request!)

Set servers

servers =[18531]

then in

def getresults(): """Function to generate speedtest result.""" spdtest = speedtest.Speedtest() spdtest.get_servers(servers) spdtest.get_best_server() download = round(spdtest.download() / 1000 / 1000, 2) upload = round(spdtest.upload() / 1000 / 1000, 2) ping = round(spdtest.results.ping)

return(download, upload, ping)
  1. Add another column into the spreadsheet to show what server ID was used. The reason here is, I have a test that can use a few different servers. Knowing which one is giving data can help me understand the results better. I.e., Comcast speedtest server is typically faster than the Wave Broadband one. So that aligns with the graph and helps me better diagnose issues with the connection.

SecuritySimon avatar Apr 18 '19 05:04 SecuritySimon