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

Switch to using importlib.metadata #62

Merged
merged 2 commits into from
Jan 14, 2023

Conversation

s-t-e-v-e-n-k
Copy link
Contributor

pkg_resources is a little heavyweight, and has some rather glaring
shortcomings for checking the metadata of an install Python package.
importlib.metadata is contained in the standard library (as of 3.8), and
provides a much nicer interface. Switch to using it, falling back to
importlib_metadata if the Python version is too old.

@jquast
Copy link
Owner

jquast commented Jul 22, 2022

Thanks for this, this all seems sensible. I will have this PR merged for next release with #61

I was just working with pkg_resources in my day job so I appreciate you teaching me about this importlib.metadata :)

jquast
jquast previously approved these changes Jul 22, 2022
setup.py Outdated Show resolved Hide resolved
pkg_resources is a little heavyweight, and has some rather glaring
shortcomings for checking the metadata of an install Python package.
importlib.metadata is contained in the standard library (as of 3.8), and
provides a much nicer interface. Switch to using it, falling back to
importlib_metadata if the Python version is too old.
tox.ini Outdated Show resolved Hide resolved
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Copy link
Contributor

@hugovk hugovk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

@jquast jquast merged commit 47b235c into jquast:master Jan 14, 2023
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

Successfully merging this pull request may close these issues.

3 participants