[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [depictor/master] Turn time_to_report_half_network into hours. #33099



commit 2a908d2c5cf377c2bdbd16794282cad45eba2319
Author: Tom Ritter <tom@xxxxxxxxx>
Date:   Wed Feb 5 11:19:34 2020 -0600

    Turn time_to_report_half_network into hours. #33099
---
 website.py | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/website.py b/website.py
index 2f5d299..1bdbd28 100755
--- a/website.py
+++ b/website.py
@@ -1105,6 +1105,9 @@ class WebsiteWriter:
 						if h == "timestamp":
 							friendly = datetime.datetime.utcfromtimestamp(int(vote.bandwidth_file_headers[h])).isoformat().replace("T", " ")
 							self.site.write("(" + friendly + ") ")
+						elif h == "time_to_report_half_network":
+							friendly = round(float(vote.bandwidth_file_headers[h]) / (60 * 60), 2)
+							self.site.write("(" + str(friendly) + " hours) ")
 					for h in vote.bandwidth_file_digest:
 						self.site.write(h + "=" + vote.bandwidth_file_digest[h] + " ")
 					self.site.write("</td>\n"

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits