[bugfix] add api process rank in default multimodal request (#36150)

Signed-off-by: fake0fan <645327136@qq.com>
Signed-off-by: Chenguang ZHENG <645327136@qq.com>
This commit is contained in:
Chenguang Zheng
2026-03-06 20:00:09 +08:00
committed by GitHub
parent e2090bf3af
commit fcb73f306c
7 changed files with 46 additions and 9 deletions

View File

@@ -39,9 +39,15 @@ class MockModelConfig:
is_multimodal_model: bool = False
@dataclass
class MockParallelConfig:
_api_process_rank: int = 0
@dataclass
class MockVllmConfig:
model_config: MockModelConfig
parallel_config: MockParallelConfig
@pytest.mark.asyncio
@@ -57,7 +63,7 @@ async def test_async_mistral_tokenizer_does_not_block_event_loop():
mock_tokenizer = Mock(spec=MistralTokenizer)
mock_tokenizer.apply_chat_template = mocked_apply_chat_template
mock_renderer = MistralRenderer(
MockVllmConfig(mock_model_config),
MockVllmConfig(mock_model_config, parallel_config=MockParallelConfig()),
tokenizer=mock_tokenizer,
)