Merge pull request 'Replaced deprecated module pkg_resources' (#311) from ribetm/py312 into master
Reviewed-on: #311
This commit is contained in:
commit
12ceea413c
1 changed files with 3 additions and 3 deletions
|
@ -1,6 +1,6 @@
|
||||||
from pkg_resources import DistributionNotFound, get_distribution
|
from importlib.metadata import version as _get_version, PackageNotFoundError
|
||||||
|
|
||||||
try:
|
try:
|
||||||
__version__ = get_distribution(__name__).version
|
__version__ = _get_version(__name__)
|
||||||
except DistributionNotFound:
|
except PackageNotFoundError:
|
||||||
pass
|
pass
|
||||||
|
|
Loading…
Reference in a new issue