[CI] Ignore ruff D209, rejoin the docstrings it split, and silence incompatible-rule warnings (#57212)
Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com> Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
1085b64425
commit
651a88c09a
@@ -1,8 +1,7 @@
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
# SPDX-FileCopyrightText: Copyright contributors to the vLLM project
|
||||
"""Test that batched_count_greater_than does not trigger 0/1 specialization
|
||||
recompiles when batch_size varies.
|
||||
"""
|
||||
recompiles when batch_size varies."""
|
||||
|
||||
import torch
|
||||
|
||||
|
||||
@@ -573,8 +573,7 @@ def test_logprobs_mode(logprobs_mode: LogprobsMode):
|
||||
def test_prompt_logprobs_mode():
|
||||
"""prompt_logprobs must respect logprobs_mode: *_logits and *_logprobs
|
||||
must return different values. Prompt tokens skip sampling processors,
|
||||
so processed_* == raw_* on the prompt side.
|
||||
"""
|
||||
so processed_* == raw_* on the prompt side."""
|
||||
from vllm import LLM
|
||||
|
||||
values: dict[str, float] = {}
|
||||
|
||||
@@ -54,8 +54,7 @@ def create_logits_tensor(
|
||||
token_idx_to_override: int | None = None,
|
||||
) -> torch.Tensor:
|
||||
"""Helper function to create logits tensor that
|
||||
will produce desired token ids on argmax
|
||||
"""
|
||||
will produce desired token ids on argmax"""
|
||||
token_ids = [tokens[:-1] for tokens in output_token_ids]
|
||||
num_total_tokens = sum(len(tokens) for tokens in token_ids)
|
||||
logits = torch.full((num_total_tokens, vocab_size), -100.0, device=DEVICE_TYPE)
|
||||
|
||||
@@ -884,8 +884,7 @@ class TestFlashInferTopkToppRobustness:
|
||||
|
||||
def _make_logits(self, pattern: str) -> torch.Tensor:
|
||||
"""Build (BATCH, VOCAB) logits with `pattern` applied to row 0
|
||||
(rows 1..B-1 stay clean so we can detect cross-row corruption).
|
||||
"""
|
||||
(rows 1..B-1 stay clean so we can detect cross-row corruption)."""
|
||||
logits = (
|
||||
torch.randn(
|
||||
self.BATCH,
|
||||
|
||||
@@ -204,8 +204,7 @@ def fake_update_logitsprocs_state(
|
||||
batch_update: BatchUpdate | None,
|
||||
) -> None:
|
||||
"""Imitate logits processors persistent batch state update
|
||||
in engine core
|
||||
"""
|
||||
in engine core"""
|
||||
for logitproc in test_fakes.get_logitsprocs():
|
||||
logitproc.update_state(batch_update)
|
||||
holder = test_fakes.sampling_metadata.thinking_budget_state_holder
|
||||
|
||||
Reference in New Issue
Block a user