Consider running the following code (note that this is an extremely simplified version to demonstrate the problem):
import matplotlib.pyplot as plot from tkinter import *
Closing the first window will work fine, but closing the second window will cause the code to hang because root.mainloop() causes an infinite loop. This problem is caused by calling fig = plot.figure(figsize=(16.8, 8.0)) . Does anyone know how to get root to complete successfully after calling matplotlib.pyplot?
python matplotlib tkinter
TheoretiCAL
source share