Skip to content

Commit 05d0db4

Browse files
committed
fix mypy issues
1 parent a529108 commit 05d0db4

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

tests/serve/lora_utils.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@ def create_bucket(self) -> None:
158158
f"s3://{self.config.bucket}",
159159
],
160160
capture_output=True,
161+
text=True,
161162
env=env,
162163
)
163164

@@ -174,6 +175,7 @@ def create_bucket(self) -> None:
174175
f"s3://{self.config.bucket}",
175176
],
176177
capture_output=True,
178+
text=True,
177179
env=env,
178180
)
179181
if result.returncode != 0:
@@ -237,6 +239,7 @@ def upload_lora(self, local_path: str) -> None:
237239
"*.git*",
238240
],
239241
capture_output=True,
242+
text=True,
240243
env=env,
241244
)
242245

tests/serve/test_vllm.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
import os
77
import random
88
from dataclasses import dataclass, field
9+
from typing import Optional
910

1011
import pytest
1112

@@ -603,8 +604,8 @@ def __init__(
603604
s3_uri: str,
604605
system_port: int = 8081,
605606
repeat_count: int = 1,
606-
expected_response: list = None,
607-
expected_log: list = None,
607+
expected_response: Optional[list] = None,
608+
expected_log: Optional[list] = None,
608609
timeout: int = 60,
609610
):
610611
super().__init__(
@@ -680,8 +681,8 @@ def lora_chat_payload(
680681
s3_uri: str,
681682
system_port: int = 8081,
682683
repeat_count: int = 2,
683-
expected_response: list = None,
684-
expected_log: list = None,
684+
expected_response: Optional[list] = None,
685+
expected_log: Optional[list] = None,
685686
max_tokens: int = 100,
686687
temperature: float = 0.0,
687688
) -> LoraTestChatPayload:

tests/utils/payloads.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
from dataclasses import dataclass
2121
from typing import Any, Callable, Dict, List, Optional
2222

23-
from dynamo import prometheus_names
23+
from dynamo import prometheus_names # type: ignore[attr-defined]
2424

2525
logger = logging.getLogger(__name__)
2626

0 commit comments

Comments
 (0)