formatting update
This commit is contained in:
parent
b77e2a9809
commit
02439f6ec4
@ -27,6 +27,7 @@ def read_dict():
|
|||||||
def print_stats():
|
def print_stats():
|
||||||
NETWORK = read_dict()
|
NETWORK = read_dict()
|
||||||
if NETWORK != "None":
|
if NETWORK != "None":
|
||||||
|
print('NETWORK STATISTICS REPORT')
|
||||||
for ipsc in NETWORK:
|
for ipsc in NETWORK:
|
||||||
stat = NETWORK[ipsc]['MASTER']['STATUS']
|
stat = NETWORK[ipsc]['MASTER']['STATUS']
|
||||||
print(ipsc)
|
print(ipsc)
|
||||||
@ -41,6 +42,7 @@ def print_stats():
|
|||||||
stat = NETWORK[ipsc]['PEERS'][peer]['STATUS']
|
stat = NETWORK[ipsc]['PEERS'][peer]['STATUS']
|
||||||
print(' RADIO ID: {} CONNECTED: {}, KEEP ALIVES: SENT {} RECEIVED {} MISSED {}'.format(str(int_id(peer)).rjust(8,'0'),stat['CONNECTED'],stat['KEEP_ALIVES_SENT'],stat['KEEP_ALIVES_RECEIVED'],stat['KEEP_ALIVES_MISSED']))
|
print(' RADIO ID: {} CONNECTED: {}, KEEP ALIVES: SENT {} RECEIVED {} MISSED {}'.format(str(int_id(peer)).rjust(8,'0'),stat['CONNECTED'],stat['KEEP_ALIVES_SENT'],stat['KEEP_ALIVES_RECEIVED'],stat['KEEP_ALIVES_MISSED']))
|
||||||
print()
|
print()
|
||||||
|
print()
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
output_stats = task.LoopingCall(print_stats)
|
output_stats = task.LoopingCall(print_stats)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user