We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3a1f3d1 commit 1e31969Copy full SHA for 1e31969
pymilvus/client/__init__.py
@@ -2,17 +2,16 @@
2
import re
3
import subprocess
4
from contextlib import suppress
5
-
6
-from pkg_resources import DistributionNotFound, get_distribution
+from importlib.metadata import version, PackageNotFoundError
7
8
log = logging.getLogger(__name__)
9
10
11
__version__ = "0.0.0.dev"
12
13
14
-with suppress(DistributionNotFound):
15
- __version__ = get_distribution("pymilvus").version
+with suppress(PackageNotFoundError):
+ __version__ = version("pymilvus")
16
17
18
def get_commit(version: str = "", short: bool = True) -> str:
0 commit comments