Update deprecated Python 3.8 typing (#13971)
This commit is contained in:
@@ -4,7 +4,7 @@ import asyncio
|
||||
from concurrent.futures import ThreadPoolExecutor
|
||||
from functools import partial
|
||||
from time import sleep
|
||||
from typing import Any, List, Tuple
|
||||
from typing import Any
|
||||
|
||||
import pytest
|
||||
|
||||
@@ -17,7 +17,7 @@ from vllm.worker.worker_base import WorkerWrapperBase
|
||||
class DummyWorkerWrapper(WorkerWrapperBase):
|
||||
"""Dummy version of vllm.worker.worker.Worker"""
|
||||
|
||||
def worker_method(self, worker_input: Any) -> Tuple[int, Any]:
|
||||
def worker_method(self, worker_input: Any) -> tuple[int, Any]:
|
||||
sleep(0.05)
|
||||
|
||||
if isinstance(worker_input, Exception):
|
||||
@@ -27,7 +27,7 @@ class DummyWorkerWrapper(WorkerWrapperBase):
|
||||
return self.rpc_rank, input
|
||||
|
||||
|
||||
def _start_workers() -> Tuple[List[ProcessWorkerWrapper], WorkerMonitor]:
|
||||
def _start_workers() -> tuple[list[ProcessWorkerWrapper], WorkerMonitor]:
|
||||
result_handler = ResultHandler()
|
||||
vllm_config = VllmConfig()
|
||||
workers = [
|
||||
|
||||
Reference in New Issue
Block a user