Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Two suggestions for improvements #29

Open
SecuritySimon opened this issue Apr 18, 2019 · 0 comments
Open

Two suggestions for improvements #29

SecuritySimon opened this issue Apr 18, 2019 · 0 comments

Comments

@SecuritySimon
Copy link

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.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant