File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 11"""datajudge allows to assess whether data from database complies with reference
22information."""
33
4- import pkg_resources
4+ import importlib . metadata
55
66from .constraints .base import Constraint
77from .db_access import Condition
1616]
1717
1818try :
19- __version__ = pkg_resources . get_distribution (__name__ ).version
19+ __version__ = importlib . metadata . distribution (__name__ ).version
2020except Exception :
2121 __version__ = "1.8.0"
Original file line number Diff line number Diff line change 11from typing import Iterable
22
33import pytest
4- from pkg_resources import parse_version
4+ from packaging . version import Version
55
66from .constraints .base import Constraint
77from .db_access import apply_patches
@@ -22,7 +22,7 @@ def get_formatter(pytestconfig):
2222 try :
2323 import pytest_html
2424
25- if parse_version (pytest_html .__version__ ).major >= 4 :
25+ if Version (pytest_html .__version__ ).major >= 4 :
2626 return AnsiColorFormatter ()
2727 finally :
2828 return Formatter ()
You can’t perform that action at this time.
0 commit comments