Skip to content

Commit

Permalink
Replace pkg_resources with importlib
Browse files Browse the repository at this point in the history
  • Loading branch information
lahtinep committed Feb 29, 2024
1 parent 6373dee commit cdb62b6
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions trollflow2/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,9 @@
# are not necessary
"""Base module for trollflow2."""

from importlib.metadata import version
from multiprocessing import Manager

from pkg_resources import DistributionNotFound, get_distribution

MP_MANAGER = Manager()

try:
__version__ = get_distribution(__name__).version
except DistributionNotFound:
# package is not installed
pass
__version__ = version(__name__)

0 comments on commit cdb62b6

Please sign in to comment.