[tor-commits] [chutney/master] Log test status less frequently: travis thinks it is too verbose.

teor at torproject.org teor at torproject.org
Thu Jun 20 07:45:41 UTC 2019


commit c5184442a3695d0dad36d7f310d047e5e95ba0c1
Author: Nick Mathewson <nickm at torproject.org>
Date:   Fri May 10 15:24:26 2019 -0400

    Log test status less frequently: travis thinks it is too verbose.
---
 lib/chutney/Traffic.py | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lib/chutney/Traffic.py b/lib/chutney/Traffic.py
index 7199f87..f2448a8 100755
--- a/lib/chutney/Traffic.py
+++ b/lib/chutney/Traffic.py
@@ -400,12 +400,16 @@ class TrafficTester(object):
     def run(self):
         start = now = time.time()
         end = time.time() + self.timeout
+        DUMP_TEST_STATUS_INTERVAL=0.5
+        dump_at = start+DUMP_TEST_STATUS_INTERVAL
         while now < end and not self.tests.all_done():
             # run only one iteration at a time, with a nice short timeout, so we
             # can actually detect completion and timeouts.
             asyncore.loop(0.2, False, None, 1)
             now = time.time()
-            debug("Test status: %s"%self.tests.status())
+            if now > dump_at:
+                debug("Test status: %s"%self.tests.status())
+                dump_at += DUMP_TEST_STATUS_INTERVAL
 
         if not debug_flag:
             sys.stdout.write('\n')





More information about the tor-commits mailing list