Skip to content

Commit

Permalink
Added strip() to tidy up speedtest result
Browse files Browse the repository at this point in the history
  • Loading branch information
wifinigel committed Aug 29, 2020
1 parent 9c492c5 commit 7dc327b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion BakeBit/Software/Python/modules/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def show_speedtest(self, g_vars):
speedtest_cmd = "speedtest | egrep -w \"Testing from|Download|Upload\" | sed -r 's/Testing from.*?\(/My IP: /g; s/\)\.\.\.//g; s/Download/D/g; s/Upload/U/g; s/bit\/s/bps/g'"

try:
speedtest_output = subprocess.check_output(speedtest_cmd, shell=True).decode()
speedtest_output = subprocess.check_output(speedtest_cmd, shell=True).decode().strip()
speedtest_info = speedtest_output.split('\n')
except subprocess.CalledProcessError as exc:
output = exc.output.decode()
Expand Down

0 comments on commit 7dc327b

Please sign in to comment.