graphstats: Fix matplotlib import error

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2019-11-10 10:18:31 -05:00
parent bdc7383e51
commit 064804b688
1 changed files with 1 additions and 0 deletions

View File

@ -51,6 +51,7 @@ def parse_log(logname, mcu):
return out return out
def setup_matplotlib(output_to_file): def setup_matplotlib(output_to_file):
global matplotlib
if output_to_file: if output_to_file:
matplotlib.use('Agg') matplotlib.use('Agg')
import matplotlib.pyplot, matplotlib.dates, matplotlib.font_manager import matplotlib.pyplot, matplotlib.dates, matplotlib.font_manager