Gevent block time resolution log to ms

This commit is contained in:
shortcutme 2019-11-30 02:09:14 +01:00
parent f0c10efca6
commit 5c93aadce3
No known key found for this signature in database
GPG key ID: 5B63BAE6CB9613AE

View file

@ -78,7 +78,7 @@ def testBlock():
while 1:
time.sleep(1)
if time.time() - last_time > 1.1:
logging.debug("Gevent block detected: %s" % (time.time() - last_time - 1))
logging.debug("Gevent block detected: %.3fs" % (time.time() - last_time - 1))
num_block += 1
last_time = time.time()
gevent.spawn(testBlock)