cli[minor]: Add __version__ (#20903)

Add __version__ to cli
This commit is contained in:
Eugene Yurtsev
2024-04-25 15:51:33 -04:00
committed by GitHub
parent 1202017c56
commit a5028b6356

View File

@@ -0,0 +1,8 @@
from importlib import metadata
try:
__version__ = metadata.version(__package__)
except metadata.PackageNotFoundError:
# Case where package metadata is not available.
__version__ = ""
del metadata # optional, avoids polluting the results of dir(__package__)