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
33f227e1
Unverified
Commit
33f227e1
authored
Mar 08, 2025
by
Cyrus Leung
Committed by
GitHub
Mar 08, 2025
Browse files
[CI/Build] Use a fixed seed to avoid flaky tests (#14480)
Signed-off-by:
DarkLight1337
<
tlleungac@connect.ust.hk
>
parent
cfd0ae82
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
6 deletions
+7
-6
tests/entrypoints/openai/test_chat_echo.py
tests/entrypoints/openai/test_chat_echo.py
+0
-2
tests/entrypoints/openai/test_metrics.py
tests/entrypoints/openai/test_metrics.py
+0
-2
tests/entrypoints/openai/test_root_path.py
tests/entrypoints/openai/test_root_path.py
+0
-2
tests/utils.py
tests/utils.py
+7
-0
No files found.
tests/entrypoints/openai/test_chat_echo.py
View file @
33f227e1
...
...
@@ -24,8 +24,6 @@ def server():
"4080"
,
"--chat-template"
,
DUMMY_CHAT_TEMPLATE
,
"--seed"
,
"0"
,
]
with
RemoteOpenAIServer
(
MODEL_NAME
,
args
)
as
remote_server
:
...
...
tests/entrypoints/openai/test_metrics.py
View file @
33f227e1
...
...
@@ -47,8 +47,6 @@ def default_server_args():
"--enforce-eager"
,
"--max-num-seqs"
,
"128"
,
"--seed"
,
"0"
,
]
...
...
tests/entrypoints/openai/test_root_path.py
View file @
33f227e1
...
...
@@ -30,8 +30,6 @@ def server():
"/"
+
ROOT_PATH
,
"--chat-template"
,
DUMMY_CHAT_TEMPLATE
,
"--seed"
,
"0"
,
]
envs
=
os
.
environ
.
copy
()
...
...
tests/utils.py
View file @
33f227e1
...
...
@@ -76,6 +76,7 @@ class RemoteOpenAIServer:
vllm_serve_args
:
list
[
str
],
*
,
env_dict
:
Optional
[
dict
[
str
,
str
]]
=
None
,
seed
:
Optional
[
int
]
=
0
,
auto_port
:
bool
=
True
,
max_wait_seconds
:
Optional
[
float
]
=
None
)
->
None
:
if
auto_port
:
...
...
@@ -87,6 +88,12 @@ class RemoteOpenAIServer:
vllm_serve_args
=
vllm_serve_args
+
[
"--port"
,
str
(
get_open_port
())
]
if
seed
is
not
None
:
if
"--seed"
in
vllm_serve_args
:
raise
ValueError
(
"You have manually specified the seed "
f
"when `seed=
{
seed
}
`."
)
vllm_serve_args
=
vllm_serve_args
+
[
"--seed"
,
str
(
seed
)]
parser
=
FlexibleArgumentParser
(
description
=
"vLLM's remote OpenAI server."
)
...
...
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