Commit e840a040 by Bjorn Neergaard

fix: use importlib_metadata on python <3.10

We updated our version of importlib_metadata, so we might as well take
advantage of it to have full compatibility with the features introduced
in Python 3.10.
parent a2fb7723
...@@ -5,8 +5,10 @@ import sys ...@@ -5,8 +5,10 @@ import sys
from contextlib import suppress from contextlib import suppress
if sys.version_info < (3, 8): # TODO: use try/except ImportError when
# compatibility for python <3.8 # https://github.com/python/mypy/issues/1393 is fixed
if sys.version_info < (3, 10):
# compatibility for python <3.10
import importlib_metadata as metadata import importlib_metadata as metadata
else: else:
from importlib import metadata from importlib import metadata
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment