config: the forwarding slots go; the dispatcher calls the family directly (#36792)

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Cheng Wan
2026-08-28 10:26:29 -07:00
committed by GitHub
co-authored by Claude Opus 5
parent 7bc3204117
commit ef20fab38a
23 changed files with 617 additions and 800 deletions
@@ -26,6 +26,7 @@ import json
import unittest
from types import SimpleNamespace
from sglang.srt.arg_groups.validation_hook import check_load_publish_args
from sglang.srt.entrypoints import http_server
from sglang.srt.lora.lora_registry import LoRARef
from sglang.srt.managers.tokenizer_manager import TokenizerManager
@@ -530,7 +531,7 @@ class TestLoadPublishEndpointValidation(CustomTestCase):
def test_requires_kv_events_config(self):
args = ServerArgs(model_path="dummy", load_publish_endpoint="tcp://*:6000")
with self.assertRaisesRegex(ValueError, "kv-events"):
args.check_load_publish_args()
check_load_publish_args(args)
def test_rejects_non_bindable_endpoint(self):
args = ServerArgs(
@@ -539,7 +540,7 @@ class TestLoadPublishEndpointValidation(CustomTestCase):
load_publish_endpoint="tcp://10.0.0.5:6000",
)
with self.assertRaisesRegex(ValueError, "bindable"):
args.check_load_publish_args()
check_load_publish_args(args)
def test_rejects_endpoint_overlapping_the_kv_range(self):
args = ServerArgs(
@@ -549,7 +550,7 @@ class TestLoadPublishEndpointValidation(CustomTestCase):
load_publish_endpoint="tcp://*:5558",
)
with self.assertRaisesRegex(ValueError, "overlaps"):
args.check_load_publish_args()
check_load_publish_args(args)
def test_rejects_null_publisher(self):
# publisher='null' disables KV events, so there is nothing to advertise
@@ -560,7 +561,7 @@ class TestLoadPublishEndpointValidation(CustomTestCase):
load_publish_endpoint="auto",
)
with self.assertRaisesRegex(ValueError, "null"):
args.check_load_publish_args()
check_load_publish_args(args)
def test_rejects_unparseable_kv_events_config(self):
args = ServerArgs(
@@ -569,7 +570,7 @@ class TestLoadPublishEndpointValidation(CustomTestCase):
load_publish_endpoint="auto",
)
with self.assertRaisesRegex(ValueError, "not parseable"):
args.check_load_publish_args()
check_load_publish_args(args)
def test_off_and_valid_endpoint_pass(self):
for endpoint in (None, "off", "OFF", "auto", "tcp://*:6000"):
@@ -581,7 +582,7 @@ class TestLoadPublishEndpointValidation(CustomTestCase):
),
load_publish_endpoint=endpoint,
)
args.check_load_publish_args() # must not raise
check_load_publish_args(args) # must not raise
if __name__ == "__main__":