Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
d9ac9e3d
Unverified
Commit
d9ac9e3d
authored
Apr 21, 2025
by
wangxiyuan
Committed by
GitHub
Apr 21, 2025
Browse files
[Misc] fix collect_env version parse (#15267)
Signed-off-by:
wangxiyuan
<
wangxiyuan1007@gmail.com
>
parent
d41faaf9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
5 deletions
+12
-5
vllm/collect_env.py
vllm/collect_env.py
+12
-5
No files found.
vllm/collect_env.py
View file @
d9ac9e3d
...
...
@@ -282,11 +282,18 @@ def get_vllm_version():
if
__version__
==
"dev"
:
return
"N/A (dev)"
if
len
(
__version_tuple__
)
==
4
:
# dev build
git_sha
=
__version_tuple__
[
-
1
][
1
:]
# type: ignore
return
f
"
{
__version__
}
(git sha:
{
git_sha
}
"
version_str
=
__version_tuple__
[
-
1
]
if
isinstance
(
version_str
,
str
)
and
version_str
.
startswith
(
'g'
):
# it's a dev build
if
'.'
in
version_str
:
# it's a dev build containing local changes
git_sha
=
version_str
.
split
(
'.'
)[
0
][
1
:]
date
=
version_str
.
split
(
'.'
)[
-
1
][
1
:]
return
f
"
{
__version__
}
(git sha:
{
git_sha
}
, date:
{
date
}
)"
else
:
# it's a dev build without local changes
git_sha
=
version_str
[
1
:]
# type: ignore
return
f
"
{
__version__
}
(git sha:
{
git_sha
}
)"
return
__version__
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment