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

MAINT: Remove LooseVersion #916

Merged
merged 5 commits into from
Feb 17, 2022
Merged

Conversation

larsoner
Copy link
Contributor

I don't like seeing in my Python 3.10 builds:

/home/larsoner/python/sphinx-gallery/sphinx_gallery/py_source_parser.py:105: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.           

So I removed one unnecessary comparison about python version (we require 3.7 already), and another involving matplotlib version that just triaged which GIF writer to use -- 3.3.1 is almost 2 years old, and the GIF-writing bug will only happen if someone actually uses GIFs in their docs and uses a quite old matplotlib version, which I think is rare enough not to worry about.

@larsoner
Copy link
Contributor Author

Pushed a fix for this, too:

  File "/home/circleci/python_env/lib/python3.8/site-packages/sphinx_gallery/backreferences.py", line 99, in get_mapping
    obj = getattr(obj, level)
RuntimeError: wrapped C/C++ object of type PyQtGraphBrowser has been deleted

We just need to except Exception rather than except AttributeError

@larsoner larsoner merged commit 877206c into sphinx-gallery:master Feb 17, 2022
@larsoner larsoner deleted the version branch February 17, 2022 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants