openwisp / openwisp-monitoring

Network monitoring system written in Python and Django, designed to be extensible, programmable, scalable and easy to use by end users: once the system is configured, monitoring checks, alerts and metric collection happens automatically.
https://openwisp.io/docs/dev/monitoring/
Other
163 stars 110 forks source link

[bug] Code issue when writing traffic rx/tx #595

Open cbeaujoin-stellar opened 1 month ago

cbeaujoin-stellar commented 1 month ago

https://github.com/openwisp/openwisp-monitoring/blob/fb2814b6dd8213ddb45a8497cf41dfb10eee04a2/openwisp_monitoring/device/writer.py#L85

It should be:

          if (
                ifstats.get('rx_bytes') is not None
                and ifstats.get('tx_bytes') is not None
            ):