More print updates
This commit is contained in:
parent
aa6e53e2fa
commit
82a12276bb
|
@ -184,9 +184,9 @@ class MsgBusServer(object):
|
|||
.format(_interval, total, self.counter_local_messages, self.counter_remote_messages)
|
||||
totals_lifetime = "Lifetime {}s {} (L:{} R: {})" \
|
||||
.format(round(uptime), total_life, counter_local_total, counter_remote_total)
|
||||
tps_interval = "Tps: {}s: {} (L:{} R:{})" \
|
||||
tps_interval = "Tps: {}s: {}/s (L:{} R:{})" \
|
||||
.format(_interval,
|
||||
total, round(total / _interval, 2),
|
||||
round(total / _interval, 2),
|
||||
round(self.counter_local_messages / _interval, 2),
|
||||
round(self.counter_remote_messages / _interval, 2))
|
||||
tps_lifetime = "Lifetime {}s {} (L:{} R: {})" \
|
||||
|
@ -194,8 +194,9 @@ class MsgBusServer(object):
|
|||
round(total_life / uptime, 2),
|
||||
round(counter_local_total / uptime, 2),
|
||||
round(counter_remote_total / uptime, 2))
|
||||
print("{: <40} {: <40}\n{: <40} {: <40}"
|
||||
.format(totals_local, totals_lifetime, tps_interval, tps_lifetime))
|
||||
peer_info = "Peers: total: {}: {}".format(len(self.peers), ', '.join(self.peers.keys()))
|
||||
print("{: <40} {: <40}\n{: <40} {: <40}\n{}"
|
||||
.format(totals_local, totals_lifetime, tps_interval, tps_lifetime, peer_info))
|
||||
self.counter_local_messages = 0
|
||||
self.counter_remote_messages = 0
|
||||
last = time()
|
||||
|
|
Loading…
Reference in New Issue