From 5204cebe0e8cf3c7537bdca81a751ae180b1fb3f Mon Sep 17 00:00:00 2001 From: Pavel 'LEdoian' Turinsky Date: Thu, 8 Feb 2024 08:07:26 +0100 Subject: [PATCH] clear plot just before, not at random place --- fosdem_video_progress.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/fosdem_video_progress.py b/fosdem_video_progress.py index 63ad3b8..360af62 100755 --- a/fosdem_video_progress.py +++ b/fosdem_video_progress.py @@ -56,6 +56,8 @@ def main(): print('pickle saved') # Show the plot + plt.close() + plt.clf() x = sorted(ts.data.keys()) # times ys = [tuple(ts.data[time][0].get(state, 0) for state in ts.states) for time in x] # numbers per state # We do not show jobstates atm. Too lazy. @@ -66,8 +68,5 @@ def main(): plt.show(block=False) plt.pause(poll_rate) - plt.close() - plt.clf() - main()