diff --git a/klippy/extras/statistics.py b/klippy/extras/statistics.py index 90cd53f8..9e6188a8 100644 --- a/klippy/extras/statistics.py +++ b/klippy/extras/statistics.py @@ -65,8 +65,8 @@ class PrinterStats: def generate_stats(self, eventtime): stats = [cb(eventtime) for cb in self.stats_cb] if max([s[0] for s in stats]): - logging.info("Stats %.1f: %s", eventtime, - ' '.join([s[1] for s in stats])) + stats_str = ' '.join([s[1] for s in stats if s[1]]) + logging.info("Stats %.1f: %s", eventtime, stats_str) return eventtime + 1. def load_config(config):