lib/nodes.py throws ZeroDivisionError. Somehow d['total'] seems not to be a decimal sometimes - maybe when nodes do not provide the information
Here is the trace:
Traceback (most recent call last):
File "./backend.py", line 170, in <module>
main(options)
File "./backend.py", line 90, in main
nodes.import_statistics(nodedb['nodes'], alfred.statistics())
File "/srv/ffmap-backend-new-troisdorf/lib/nodes.py", line 74, in import_statistics
lambda d: 1 - d['free'] / d['total'])
File "/srv/ffmap-backend-new-troisdorf/lib/nodes.py", line 61, in add
statistics))
File "/srv/ffmap-backend-new-troisdorf/lib/nodes.py", line 74, in <lambda>
lambda d: 1 - d['free'] / d['total'])
ZeroDivisionError: division by zero
lib/nodes.py throws ZeroDivisionError. Somehow
d['total']
seems not to be a decimal sometimes - maybe when nodes do not provide the informationHere is the trace:
Simple solution (replace line 74 with):