[Misc] Add generated git commit hash as vllm.__commit__ (#6386)

This commit is contained in:
Michael Goin
2024-07-12 22:52:15 +00:00
committed by GitHub
parent 75f64d8b94
commit 111fc6e7ec
5 changed files with 47 additions and 1 deletions
+11
View File
@@ -1 +1,12 @@
import warnings
try:
import vllm.commit_id
__commit__ = vllm.commit_id.__commit__
except Exception as e:
warnings.warn(f"Failed to read commit hash:\n{e}",
RuntimeWarning,
stacklevel=2)
__commit__ = "COMMIT_HASH_PLACEHOLDER"
__version__ = "0.5.1"