Skip to content

Commit 2708965

Browse files
committed
typehints
1 parent 7b8b0ef commit 2708965

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

whispercpppy/server.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ class WhisperCppServerOptions(BaseModel):
7878
flash_attn: bool = Field(default=False, description="--flash-attn")
7979

8080

81-
def field_to_cli_arg(flag: str, value) -> list[str] | None:
81+
def field_to_cli_arg(flag: str, value: Any) -> list[str] | None:
8282
if value is None:
8383
return None
8484
if type(value) is bool:
@@ -206,7 +206,7 @@ def __init__(
206206
self._vad_options = vad_options
207207

208208
self._binary = binary
209-
self._process: subprocess.Popen[str] | None = None
209+
self._process: subprocess.Popen[bytes] | None = None
210210
self._base_url = f"http://{server_options.host}:{server_options.port}"
211211

212212
if autostart:
@@ -220,7 +220,7 @@ def start(self) -> None:
220220
self._vad_options,
221221
self._binary,
222222
)
223-
self._process = subprocess.Popen(command) # type:ignore
223+
self._process = subprocess.Popen(command)
224224

225225
def __del__(self) -> None:
226226
try:

0 commit comments

Comments
 (0)