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
Show fails on figures created with the object-oriented system #1219
Comments
Thank you, I see where this is happening. I'm not sure yet whether this is a problem with a single changeset, or whether it is an interaction between 2 or more. I will look into it now. |
I have some more investigation to do as to how to handle this, but my first thought is that Figure.show() was never intended to be used with a figure created outside the pyplot paradigm; it was monkey-patched in by the gui backends to be used in the pyplot context. Now that it is exposed explicitly in the Figure API, it is natural to expect it to work without pyplot--but it doesn't, because it was not designed to do so. One solution would be to make this clear in the docstring and in the exception generated when it is called on an unmanaged figure. I will do this if I can't think of anything better. |
I get the same error. Using:
Steps to replicate:
|
HAHAHA, I get a quite funny solution. Define a empty class like , and assign it a attribute window=None. Then write like this: |
I get the same error. Using: Debian 10 and 11 + normal python3, python3-matplotlib, ... from Debian 10 and 11 My code:
|
Please open a new issue that has a self-contained minimal example (if the problem persists after you create the example). |
The following code fails with a:
On all all gui backends that I have tested. This seems to be because non of the canvases in any backends
have a manager attribute which is requested in the show method of the figure at line 348 in figure.py.
The text was updated successfully, but these errors were encountered: