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

remove pkg_resources, use importlib #62

Merged
merged 1 commit into from
Feb 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions atlas_densities/version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""version"""
from pkg_resources import get_distribution # type: ignore
import importlib.metadata

VERSION = get_distribution("atlas_densities").version
VERSION = importlib.metadata.version("atlas_densities")
5 changes: 2 additions & 3 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@
import os
import sys

from pkg_resources import get_distribution

import importlib.metadata

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
Expand Down Expand Up @@ -52,7 +51,7 @@
# built documents.
#
# The short X.Y version.
version = get_distribution(project).version
version = importlib.metadata.version(project)
# The full version, including alpha/beta/rc tags.
release = version

Expand Down
Loading