Read process groups through the runtime context (#40068)

This commit is contained in:
Cheng Wan
2026-09-18 17:40:32 -07:00
committed by GitHub
parent 5931fd60ee
commit afe71f4b9e
165 changed files with 569 additions and 608 deletions
@@ -1012,7 +1012,7 @@ class TestEncoderDelivery(CustomTestCase):
with (
patch(
"sglang.srt.disaggregation.encoder.server.get_tp_group",
"sglang.srt.distributed.parallel_state.get_tp_group",
return_value=TPGroup(),
),
patch(
@@ -1052,7 +1052,7 @@ class TestEncoderDelivery(CustomTestCase):
with (
patch(
"sglang.srt.disaggregation.encoder.server.get_tp_group",
"sglang.srt.distributed.parallel_state.get_tp_group",
return_value=TPGroup(),
),
patch(
@@ -1096,7 +1096,7 @@ class TestEncoderDelivery(CustomTestCase):
with (
patch(
"sglang.srt.disaggregation.encoder.server.get_tp_group",
"sglang.srt.distributed.parallel_state.get_tp_group",
return_value=TPGroup(),
),
patch(
@@ -201,7 +201,9 @@ class TestRegisterToBootstrap(CustomTestCase):
self.assertIn("10.0.0.1", url_used)
@patch("sglang.srt.disaggregation.common.conn.requests.put")
@patch("sglang.srt.disaggregation.common.conn.get_world_group")
# The consumer reads the group through `get_parallel()`, which reads
# through to the canonical getter, so that is where the stub belongs.
@patch("sglang.srt.distributed.parallel_state.get_world_group")
def test_rust_attention_dp_replicates_complete_topology_across_hosts(
self, mock_world_group, mock_put
):