Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

matplotlib plot does not appear in debug mode #11872

Open
vainaixr opened this issue Sep 1, 2019 · 1 comment
Open

matplotlib plot does not appear in debug mode #11872

vainaixr opened this issue Sep 1, 2019 · 1 comment

Comments

@vainaixr
Copy link

vainaixr commented Sep 1, 2019

when I attempt at plotting an image after set_trace(), it does not appear while debugging

@tacaswell
Copy link
Contributor

This is because the input hook (see matplotlib/matplotlib#4779 for gory details) is not active in the debugger so the GUI framework never gets the chance to run its event loop and update the windows.

You can do plt.pause(1) (run the GUI for 1s), plt.show(block=True) (run the GUI until you close al of the open windows), or fig.canvas.flush_events() (process the current event queue in the GUI) to get responsive (ish) windows.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants