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

Pin matplotlib version to avoid the use of deprecated draw_all in Colorbar objects #312

Closed
schavesgm opened this issue Oct 18, 2023 · 2 comments

Comments

@schavesgm
Copy link

Describe the bug
A clear and concise description of what the bug is.
cryoDRGN does not specify any required version of matplotlib in the pyproject.toml file. As a result, a clean installation of the package will try to install the latest version. However, matplotlib deprecated in version 3.6 the draw_all method on Colorbar objects in favour of draw_without_rendering. This method is used in cryodrgn analyze to generate the jupyter notebooks.

To Reproduce
What is the command you used?
cryodrgn analyze on a clean installation of cryoDRGN should raise this bug, as matplotlib's 3.8 version would be installed.

Expected behavior
A clear and concise description of what you expected to happen.
A simple solution for this bug would be to pin matplotlib's version to 3.6, which should not break anything. Another approach would be to pin matplotlib to 3.8 and modify any calls to draw_all in Colorbar objects.

Add any other context about the problem here.

@michal-g
Copy link
Collaborator

I was able to reproduce the error and fixed it by specifying matplotlib<3.7 under pyproject.toml dependencies. We'll update this in the next release!

If you haven't done so already, you can fix this in your own installation in the meantime by editing pyproject.toml yourself if you are installing from source, or using conda install matplotlib<3.7, which will also work if you are installing using pip.

@michal-g
Copy link
Collaborator

We added pinning of the matplotlib version in the v3.0.1-beta to address this issue.

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