Skip to content

Commit

Permalink
Replace Deprecated pkg_resources with importlib (#30)
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffquinn-msk authored Sep 17, 2024
1 parent a2b56e8 commit fbd0171
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions mutalyzer_hgvs_parser/__init__.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
from pkg_resources import get_distribution
from importlib.metadata import metadata

from .convert import to_model
from .hgvs_parser import parse


def _get_metadata(name):
pkg = get_distribution(__package__)
meta = metadata(__package__)

for line in pkg.get_metadata_lines(pkg.PKG_INFO):
if line.startswith("{}: ".format(name)):
return line.split(": ")[1]

return ""
return meta.get(name, "")


_copyright_notice = "Copyright (c) {} <{}>".format(
Expand Down

0 comments on commit fbd0171

Please sign in to comment.