enkore / i3pystatus

A complete replacement for i3status
https://i3pystatus.readthedocs.io/
MIT License
445 stars 188 forks source link

Fix TypeError when not using network traffic in format string #690

Closed terminalmage closed 5 years ago

terminalmage commented 5 years ago

These formatters are initialized as strings, so when they're not used we don't use use the code that updates the network counters, and the result is that we attempt to divide an empty string by the divisor value (an integer), resulting in a TypeError.

This ignores these errors, letting these formatters remain as empty strings.

terminalmage commented 5 years ago

https://github.com/enkore/i3pystatus/pull/694 includes a better fix for this, closing.