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
dynamo
Commits
57454300
"deploy/helm/vscode:/vscode.git/clone" did not exist on "71f9e7a9de9f45c1a44a1753c1ce45a8115452cb"
Unverified
Commit
57454300
authored
Aug 15, 2025
by
Graham King
Committed by
GitHub
Aug 15, 2025
Browse files
chore(sglang): Warn if --skip-tokenizer-init missing (#2463)
parent
3ef08d40
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
components/backends/sglang/src/dynamo/sglang/common/sgl_utils.py
...nts/backends/sglang/src/dynamo/sglang/common/sgl_utils.py
+12
-12
No files found.
components/backends/sglang/src/dynamo/sglang/common/sgl_utils.py
View file @
57454300
# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import
argparse
import
contextlib
...
...
@@ -22,7 +10,19 @@ from argparse import Namespace
from
sglang.srt.server_args
import
ServerArgs
class
SkipTokenizerInitError
(
RuntimeError
):
def
__init__
(
self
):
super
().
__init__
(
"--skip-tokenizer-init flag is required"
)
def
parse_sglang_args_inc
(
args
:
list
[
str
])
->
ServerArgs
:
# Currently we only support Dynamo doing the tokenization, so we must give
# sglang the skip-tokenizer-init flag. We don't default it because this is temporary.
# Allow the --version and --help flags through.
temp_need_tok
=
[
"--skip-tokenizer-init"
,
"--version"
,
"--help"
,
"-h"
]
if
not
any
(
w
in
args
for
w
in
temp_need_tok
):
raise
SkipTokenizerInitError
()
parser
=
argparse
.
ArgumentParser
()
bootstrap_port
=
_reserve_disaggregation_bootstrap_port
()
ServerArgs
.
add_cli_args
(
parser
)
...
...
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