openwisp-monitoring
openwisp-monitoring copied to clipboard
[bug] Iperf bar charts time range on x-axis is inconsistent with other charts
Reported by @pandafy in https://github.com/openwisp/openwisp-monitoring/pull/394#issuecomment-1202118479
- If we look below
stackedbar+lines
charts, time interval starts from August 1 12:00 hrs with 12 hrs time difference between each points on the x-axis.
- While other iperf charts shows time interval starts from August 1 18:00 hrs with 6 hrs time difference.
Possible solution
- I found that
options.mode = 'lines+markers'
for thestackedbar+lines
charts which streches charts x-axis to some backward time we can useoptions.mode = 'lines'
for iperf charts to avoid this.
Note : Iperf charts uses connect_points
chart property which connects only non-null values by filtering out it's existing x-axis & y-axis, therefore their start time point on x-axis is different from normal monitoring charts but all iperf charts have consistent x-axis intervals.